From 1a58525e35b119e5bcd67d78e5970e3ba0cabd44 Mon Sep 17 00:00:00 2001 From: afonsofrancof Date: Sat, 21 Oct 2023 15:18:01 +0100 Subject: [PATCH] [MINOR] Added Ocaml-lsp in nvim --- .config/nvim/lua/plugins/lspconfig.lua | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/.config/nvim/lua/plugins/lspconfig.lua b/.config/nvim/lua/plugins/lspconfig.lua index 0d4df96..688eeb4 100644 --- a/.config/nvim/lua/plugins/lspconfig.lua +++ b/.config/nvim/lua/plugins/lspconfig.lua @@ -48,14 +48,19 @@ local capabilities = vim.tbl_deep_extend( require('cmp_nvim_lsp').default_capabilities() ) +local setup = { + on_attach = on_attach, + flags = lsp_flags, + capabilities = capabilities, +} mason_lspconfig.setup_handlers { -- This is a default handler that will be called for each installed server (also for new servers that are installed during a session) function(server_name) - lspconfig[server_name].setup { - on_attach = on_attach, - flags = lsp_flags, - capabilities = capabilities, - } + lspconfig[server_name].setup { setup } end, } + +lspconfig["ocamllsp"].setup { + setup +}