1
0
Fork 0
mirror of https://github.com/pnx/dotfiles synced 2026-06-16 19:30:01 +02:00

nvim/lua/user/plugins/ide/lsp.lua: add support new nvim api (0.11+)

This commit is contained in:
Henrik Hautakoski 2025-04-28 23:58:29 +02:00
parent 68cee9f48a
commit 36939b006a

View file

@ -117,7 +117,12 @@ return {
capabilities = capabilities
}, server_opts or {})
lspconfig[server].setup(server_opts)
if vim.fn.has('nvim-0.11') then
vim.lsp.config(server, server_opts)
vim.lsp.enable(server)
else
lspconfig[server].setup(server_opts)
end
end
local have_mason, mlsp = pcall(require, "mason-lspconfig")