fix(nixvim): eliminate per-keystroke LSP completion latency
- drop lsp-lines (redundant with tiny-inline-diagnostic; double diagnostic virtual-text redraw per keystroke) - drop nvim_lsp_signature_help cmp source (extra server request per keystroke; <C-k> keymap covers it) - remove cmp-nvim-lsp-signature-help plugin (now unused) - disable LSP client file logging (nixd/svelte stderr spam was writing 5MB+ logs on the main loop) - disable rust-analyzer semantic tokens (ContentModified retry loop while typing)
This commit is contained in:
@@ -123,6 +123,11 @@
|
|||||||
};
|
};
|
||||||
lsp = {
|
lsp = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
onAttach = ''
|
||||||
|
if client.name == "rust-analyzer" then
|
||||||
|
client.server_capabilities.semanticTokensProvider = nil
|
||||||
|
end
|
||||||
|
'';
|
||||||
servers = {
|
servers = {
|
||||||
# qmlls = {
|
# qmlls = {
|
||||||
# enable = true;
|
# enable = true;
|
||||||
@@ -224,7 +229,6 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
lsp-lines.enable = true;
|
|
||||||
trouble = {
|
trouble = {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
@@ -257,10 +261,6 @@
|
|||||||
name = "nvim_lsp";
|
name = "nvim_lsp";
|
||||||
priority = 100;
|
priority = 100;
|
||||||
}
|
}
|
||||||
{
|
|
||||||
name = "nvim_lsp_signature_help";
|
|
||||||
priority = 90;
|
|
||||||
}
|
|
||||||
{
|
{
|
||||||
name = "luasnip";
|
name = "luasnip";
|
||||||
priority = 75;
|
priority = 75;
|
||||||
@@ -340,7 +340,6 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
extraPlugins = with pkgs; [
|
extraPlugins = with pkgs; [
|
||||||
vimPlugins.cmp-nvim-lsp-signature-help
|
|
||||||
tiny-code-action
|
tiny-code-action
|
||||||
];
|
];
|
||||||
opts = {
|
opts = {
|
||||||
@@ -355,6 +354,8 @@
|
|||||||
mapleader = " ";
|
mapleader = " ";
|
||||||
};
|
};
|
||||||
extraConfigLua = ''
|
extraConfigLua = ''
|
||||||
|
-- LSP client writes server stderr + errors to disk on the main loop; nixd spams info logs -> 5MB+ logs. Kill it.
|
||||||
|
vim.lsp.set_log_level("off")
|
||||||
-- tree-sitter-nix uses (#is-not? local) which the new nvim-treesitter main branch no longer registers
|
-- tree-sitter-nix uses (#is-not? local) which the new nvim-treesitter main branch no longer registers
|
||||||
vim.treesitter.query.add_predicate("is-not?", function() return true end, { force = true })
|
vim.treesitter.query.add_predicate("is-not?", function() return true end, { force = true })
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user