Adapting nvim-lsp-installer to use nvim's new vim.lsp.start #745
-
It seems that neovim/neovim#18631 is going to be merged soon and as such I was wondering if there might be a simple mechanism in this plugin to use the installed servers from this plugin easily with this new function. If you haven't seen the PR the new api looks something like vim.lsp.start({
cmd = {"<path>"},
name = "server-name",
root_dir = ...
}) A user would then call this in an autocommand or ftplugin file. The main integration point I think being just providing the cmd which is I presume what is already done automagically for nvim-lspconfig. I don't imagine that people will immediately switch to this api despite being quite straighforward since it requires having to fill out all the server configurations yourself, i.e. root dir and any other default configs, but perhaps lspconfig will just provide the settings in the future so a nice/easy way to add the details from lsp-installer would be good. I think there is already a way to fetch the path from lsp installer for a server but IIRC it's a bit involved and not advertised up front. Decided this was more of a discussion than an issue, not sure if that's quite right 🤷🏿♂️ |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
Hey! I forgot to reply here 🙈. Thanks for the heads-up, I had not seen that PR before. So I have actually for a long time been exploring symlinking executables to a single location, allowing nvim-lsp-installer to just amend the entire session's PATH once and be done with it. This would make the entire thing much more seamless without any need to register setup hooks and whatnot (it would also play much more nicely with potential installation of other tools such as linters & formatters to be used with formatter.nvim, null-ls, etc.). Haven't made it happen yet primarily because of Windows support & time. edit: also some more context in this comment |
Beta Was this translation helpful? Give feedback.
Hey! I forgot to reply here 🙈. Thanks for the heads-up, I had not seen that PR before. So I have actually for a long time been exploring symlinking executables to a single location, allowing nvim-lsp-installer to just amend the entire session's PATH once and be done with it.
This would make the entire thing much more seamless without any need to register setup hooks and whatnot (it would also play much more nicely with potential installation of other tools such as linters & formatters to be used with formatter.nvim, null-ls, etc.). Haven't made it happen yet primarily because of Windows support & time.
edit: also some more context in this comment