From aabf65cbe8db3f0b30c9b383954e0804404dc346 Mon Sep 17 00:00:00 2001 From: ShatteredMINT Date: Sun, 4 May 2025 10:22:20 +0200 Subject: [PATCH] use locally installed clangd instead --- lua/config/lsp.lua | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/lua/config/lsp.lua b/lua/config/lsp.lua index 17c0f0c..43d10d8 100644 --- a/lua/config/lsp.lua +++ b/lua/config/lsp.lua @@ -8,7 +8,7 @@ require('mason').setup({ } }) -local servers = { 'lua_ls', 'rust_analyzer', 'zls', 'jdtls', 'nil_ls' } +local servers = { 'lua_ls', 'rust_analyzer', 'zls', 'nil_ls' } require('mason-lspconfig').setup({ -- A list of servers to automatically install if they're not already installed @@ -78,3 +78,16 @@ for _, lsp in ipairs(servers) do capabilities = capabilities, } end + +lspconfig.clangd.setup({ + -- cmd = { "clangd", "--background-index", "--clang-tidy", "--log=verbose" }, + -- init_options = { + -- fallbackFlags = { "-std=c++17" }, + -- }, +}) +lspconfig.opts = { + servers = { + clangd = { + mason = false, + }, +},