pkg(nixvim): Add some lsp configuration
This commit is contained in:
parent
39ca09b05f
commit
56dc7f3bba
1 changed files with 29 additions and 5 deletions
|
|
@ -2,10 +2,34 @@
|
||||||
youthlic.plugins.lspconfig.enable = true;
|
youthlic.plugins.lspconfig.enable = true;
|
||||||
lsp = {
|
lsp = {
|
||||||
inlayHints.enable = true;
|
inlayHints.enable = true;
|
||||||
servers = {
|
luaConfig.post =
|
||||||
nixd = {
|
#lua
|
||||||
enable = true;
|
''
|
||||||
};
|
do
|
||||||
};
|
vim.diagnostic.config({
|
||||||
|
underline = true,
|
||||||
|
virtual_lines = {
|
||||||
|
current_line = true,
|
||||||
|
},
|
||||||
|
signs = true,
|
||||||
|
severity_sort = true,
|
||||||
|
float = {
|
||||||
|
scope = "cursor",
|
||||||
|
source = "if_many",
|
||||||
|
},
|
||||||
|
jump = {
|
||||||
|
on_jump = function(diagnostic, bufnr)
|
||||||
|
vim.diagnostic.open_float({
|
||||||
|
scope = "cursor",
|
||||||
|
severity_sort = true,
|
||||||
|
source = "if_many",
|
||||||
|
bufnr = bufnr,
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
wrap = true,
|
||||||
|
},
|
||||||
|
})
|
||||||
|
end
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue