neovim & lsp
If you don’t know neovim you can think about it like “vim on steroids”.
And you probably know that it is possible to add lsp support to vim
using plugins.
Well yes it is, but very difficult and error-prone, and it just breaks randomly then.
The (one of) good thing about neovim
is that it supports lsp natively.
The other good thing is that you can use lua to configure it.
Let’s bring this all together!
- Install
neovim
using the common way for your OS:
brew install neovim
-
Configure it:
-
Run it once to trigger
packer
installation:
nvim
:q
- Run it again to have
packer
active and tell it once to install all packages:
nvim
:PackerSync
:q
It won’t be required anymore in the future as long as you’ll use neovim
to also edit ~/.config/nvim/lua/user/plugins.lua
file as this file also installed AutoCmd that triggers PackerSync
every time when this file changed.
- Run
nvim
again to install alllsp
servers:
nvim
:Mason
- Enjoy!