From 6bb1e3a0a9ed2a4bcb89fdaea80c2c93be737727 Mon Sep 17 00:00:00 2001 From: xengineering Date: Fri, 1 Mar 2024 09:01:18 +0100 Subject: nvim: Refactor to support multiple LSP servers --- nvim/init.lua | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'nvim') diff --git a/nvim/init.lua b/nvim/init.lua index 2cbde67..d966034 100644 --- a/nvim/init.lua +++ b/nvim/init.lua @@ -51,9 +51,13 @@ cmp.setup({ }) local capabilities = require('cmp_nvim_lsp').default_capabilities() -require'lspconfig'.clangd.setup{ - capabilities = capabilities +local lsp = require'lspconfig' +local servers = { + 'clangd', } +for _, server in ipairs(servers) do + lsp[server].setup{capabilities = capabilities} +end require("luasnip.loaders.from_vscode").lazy_load() -- cgit v1.2.3-70-g09d2