Add nvim-lsp-installer

Might end up using this to install LSPs. Just playing with it for now.
This commit is contained in:
ViViDboarder 2021-12-31 17:32:33 -08:00
parent 175c271d90
commit 40b88432f8
3 changed files with 20 additions and 0 deletions

View File

@ -189,6 +189,12 @@ return require("packer").startup({
-- Configure language servers
use("neovim/nvim-lspconfig")
-- Install language servers
use({
"williamboman/nvim-lsp-installer",
requires = "neovim/nvim-lspconfig",
})
-- Better display of diagnostics
use("folke/trouble.nvim")

View File

@ -207,4 +207,17 @@ function M.config_null_ls()
})
end)
end
function M.config_lsp_intaller()
utils.try_require("nvim-lsp-installer", function(lsp_installer)
lsp_installer.on_server_ready(function(server)
server:setup({
on_attach = default_attach,
})
end)
end, function()
print("nvim-lsp-installer not installed")
end)
end
return M

View File

@ -3,6 +3,7 @@ local lsp_config = require("plugins.lsp")
-- Configure my various lsp stuffs
lsp_config.config_null_ls()
lsp_config.config_lsp_intaller()
lsp_config.config_lsp()
lsp_config.config_lsp_ui()