From d3de266f7fa67f973318f657ebd6c38847de5137 Mon Sep 17 00:00:00 2001 From: mjhika <1zzt6ovh@mojica.anonaddy.com> Date: Sun, 28 Jan 2024 15:05:41 -0500 Subject: [PATCH] disable LSP syntax highlighting this way nvim will prefer the treesitter highlighting --- init.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/init.lua b/init.lua index 39c53e05..3bdf7e73 100644 --- a/init.lua +++ b/init.lua @@ -248,7 +248,7 @@ vim.keymap.set('n', 'w', vim.cmd.w, { desc = 'Save buffer' }) -- [[ Configure LSP ]] -- This function gets run when an LSP connects to a particular buffer. -local on_attach = function(_, bufnr) +local on_attach = function(client, bufnr) -- Create a command `:Format` local to the LSP buffer vim.api.nvim_buf_create_user_command(bufnr, 'Format', function(_) vim.lsp.buf.format() @@ -283,6 +283,8 @@ local on_attach = function(_, bufnr) -- See `:help K` for why this keymap nmap('K', vim.lsp.buf.hover, 'Hover Documentation') nmap('', vim.lsp.buf.signature_help, 'Signature Documentation') + + client.server_capabilities.semanticTokensProvider = nil end -- Enable the following language servers