Closed overcache closed 2 years ago
This is expected behaviour. Once you setup lsp_installer=true
navigator will not run setup for the LSP. You will need to setup those LSPs in lsp_installer
setup function.
Sorry, I misunderstand the README:
Navigator will startup the server installed by lsp-installer. Please do not call server:setup{opts} from lsp installer as it will override the navigator setup
May I ask how to config lsp_installer without call server:setup{opts}
?
thanks
Sorry, my README is confusing. I put some updates.
If you are using go with gopls, the setup will be look like this:
local path = require 'nvim-lsp-installer.path'
local install_root_dir = path.concat {vim.fn.stdpath 'data', 'lsp_servers'}
require'navigator'.setup({
-- lsp_installer = false -- default value is false
lsp = {
gopls = {
cmd = { install_root_dir .. '/go/gopls' }
}
}
}
Please check the lsp binary in your install_root_dir and update thecmd
setup.
Alternatively, add those binary to PATH should also work.
Thanks, it works
I prefer config lsp_server in nvim-lsp-installer
, so I dont need to config every server's cmd path.
I installed tsserver via lsp_installer, and set
lsp_installer = true
in config, but no lsp-server launch.content of packer config
content of config:
output of
:LspPrintInstalled
output of
:LspInfo
everything works fine if I install tssever global with:
npm i -g npm install -g typescript typescript-language-servertsserver