@@ -214,6 +214,7 @@ vim.keymap.set('n', '<C-h>', '<C-w><C-h>', { desc = 'Move focus to the left wind
214
214
vim .keymap .set (' n' , ' <C-l>' , ' <C-w><C-l>' , { desc = ' Move focus to the right window' })
215
215
vim .keymap .set (' n' , ' <C-j>' , ' <C-w><C-j>' , { desc = ' Move focus to the lower window' })
216
216
vim .keymap .set (' n' , ' <C-k>' , ' <C-w><C-k>' , { desc = ' Move focus to the upper window' })
217
+
217
218
-- NOTE: Some terminals have colliding keymaps or are not able to send distinct keycodes
218
219
-- vim.keymap.set("n", "<C-S-h>", "<C-w>H", { desc = "Move window to the left" })
219
220
-- vim.keymap.set("n", "<C-S-l>", "<C-w>L", { desc = "Move window to the right" })
@@ -672,12 +673,6 @@ require('lazy').setup({
672
673
},
673
674
}
674
675
675
- -- LSP servers and clients are able to communicate to each other what features they support.
676
- -- By default, Neovim doesn't support everything that is in the LSP specification.
677
- -- When you add blink.cmp, luasnip, etc. Neovim now has *more* capabilities.
678
- -- So, we create new capabilities with blink.cmp, and then broadcast that to the servers.
679
- local capabilities = require (' blink.cmp' ).get_lsp_capabilities ()
680
-
681
676
-- Enable the following language servers
682
677
-- Feel free to add/remove any LSPs that you want here. They will automatically be installed.
683
678
--
@@ -718,6 +713,11 @@ require('lazy').setup({
718
713
},
719
714
},
720
715
}
716
+ --- @type MasonLspconfigSettings
717
+ --- @diagnostic disable-next-line : missing-fields
718
+ require (' mason-lspconfig' ).setup {
719
+ automatic_enable = vim .tbl_keys (servers or {}),
720
+ }
721
721
722
722
-- Ensure the servers and tools above are installed
723
723
--
@@ -738,19 +738,14 @@ require('lazy').setup({
738
738
})
739
739
require (' mason-tool-installer' ).setup { ensure_installed = ensure_installed }
740
740
741
- require (' mason-lspconfig' ).setup {
742
- ensure_installed = {}, -- explicitly set to an empty table (Kickstart populates installs via mason-tool-installer)
743
- automatic_installation = false ,
744
- handlers = {
745
- function (server_name )
746
- local server = servers [server_name ] or {}
747
- -- This handles overriding only values explicitly passed
748
- -- by the server configuration above. Useful when disabling
749
- -- certain features of an LSP (for example, turning off formatting for ts_ls)
750
- server .capabilities = vim .tbl_deep_extend (' force' , {}, capabilities , server .capabilities or {})
751
- end ,
752
- },
753
- }
741
+ -- Installed LSPs are configured and enabled automatically with mason-lspconfig
742
+ -- The loop below is for overriding the default configuration of LSPs with the ones in the servers table
743
+ for server_name , config in pairs (servers ) do
744
+ vim .lsp .config (server_name , config )
745
+ end
746
+
747
+ -- NOTE: Some servers may require an old setup until they are updated. For the full list refer here: https://github.com/neovim/nvim-lspconfig/issues/3705
748
+ -- These servers will have to be manually set up with require("lspconfig").server_name.setup{}
754
749
end ,
755
750
},
756
751
@@ -920,12 +915,7 @@ require('lazy').setup({
920
915
},
921
916
922
917
-- Highlight todo, notes, etc in comments
923
- {
924
- ' folke/todo-comments.nvim' ,
925
- event = ' VimEnter' ,
926
- dependencies = { ' nvim-lua/plenary.nvim' },
927
- opts = { signs = false , keywords = { TODO = { alt = { ' CSAH' } } } },
928
- },
918
+ { ' folke/todo-comments.nvim' , event = ' VimEnter' , dependencies = { ' nvim-lua/plenary.nvim' }, opts = { signs = false } },
929
919
930
920
{ -- Collection of various small independent plugins/modules
931
921
' echasnovski/mini.nvim' ,
0 commit comments