Lua only Neovim config
git clone https://github.com/wbthomason/packer.nvim\
~/.local/share/nvim/site/pack/packer/start/packer.nvim
Besides config under nvim-lspconfig
, make sure you have corresponding
language server running:
# For python
npm install -g pyright
# For go
brew install gopls
# For rust
brew install rust-analyzer
# For dockerls
npm install -g dockerfile-language-server-nodejs
- pyright doesn't provide much code_actions. it only has
codeActionKinds = { "quickfix", "source.organizeImports" }
:lua print(vim.inspect(vim.lsp.buf_get_clients(0)[1].resolved_capabilities))
- Update treesitter
When there's issue with treesitter, I found manually update source control works most of time:
cd ~/.local/share/nvim/site/pack/packer/start/nvim-treesitter
git pull --rebase origin master
Then open vim and PackerSync
- Treesitter related parser issue in vim:
TSUpdate
- Use
arch -arm64 brew
instead ofbrew
to get around wrong arch Rosseta 2 error