fix(nvim): setup lsps properly
All checks were successful
Discord / discord commits (push) Has been skipped
All checks were successful
Discord / discord commits (push) Has been skipped
This commit is contained in:
parent
0667f0f4c9
commit
c8f8dc98e6
1 changed files with 9 additions and 11 deletions
|
@ -26,13 +26,6 @@ in
|
|||
|
||||
home.packages = with pkgs; [
|
||||
alejandra
|
||||
|
||||
# FIXME: set nixd to use alejandra
|
||||
(writeShellApplication {
|
||||
name = "nixpkgs-fmt";
|
||||
runtimeInputs = [alejandra];
|
||||
text = "alejandra \"$@\"";
|
||||
})
|
||||
];
|
||||
|
||||
xdg.dataFile."${flakeDir}/.nixd.json".text = builtins.toJSON {
|
||||
|
@ -55,10 +48,15 @@ in
|
|||
lua
|
||||
*/
|
||||
''
|
||||
local lsp = require('lspconfig');
|
||||
|
||||
lsp.nixd.setup({});
|
||||
lsp.nixd.setup(require('coq').lsp_ensure_capabilities({}));
|
||||
require('lspconfig').nixd.setup(require('coq').lsp_ensure_capabilities({
|
||||
settings = {
|
||||
nixd = {
|
||||
formatting = {
|
||||
command = { "alejandra" },
|
||||
},
|
||||
},
|
||||
},
|
||||
}));
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue