75 lines
2.6 KiB
Nix
75 lines
2.6 KiB
Nix
{ inputs, pkgs, config, lib, theme, ... }: {
|
|
imports = [ ./nixvim-base.nix ];
|
|
|
|
programs.nixvim = {
|
|
plugins = {
|
|
lsp = {
|
|
enable = true;
|
|
servers = {
|
|
rust-analyzer = {
|
|
enable = true;
|
|
installCargo = true;
|
|
installRustc = true;
|
|
};
|
|
pylsp = {
|
|
enable = true;
|
|
autostart = true;
|
|
installLanguageServer = true;
|
|
settings = {
|
|
plugins = {
|
|
black = {
|
|
enabled = true;
|
|
preview = true;
|
|
};
|
|
};
|
|
};
|
|
};
|
|
nil_ls.enable = true;
|
|
html.enable = true;
|
|
cssls.enable = true;
|
|
bashls.enable = true;
|
|
};
|
|
keymaps = {
|
|
silent = true;
|
|
diagnostic = {
|
|
"<leader>lk" = {
|
|
action = "goto_prev";
|
|
desc = "Go to prev";
|
|
};
|
|
"<leader>lj" = {
|
|
action = "goto_next";
|
|
desc = "Go to next";
|
|
};
|
|
};
|
|
|
|
lspBuf = {
|
|
K = {
|
|
action = "hover";
|
|
desc = "Hover";
|
|
};
|
|
"<leader>lr" = {
|
|
action = "references";
|
|
desc = "LSP [r]eferences";
|
|
};
|
|
"<leader>ld" = {
|
|
action = "definition";
|
|
desc = "LSP [d]efinitions";
|
|
};
|
|
"<leader>li" = {
|
|
action = "implementation";
|
|
desc = "LSP [i]implementations";
|
|
};
|
|
"<leader>lt" = {
|
|
action = "type_definition";
|
|
desc = "LSP [t]ype definitions";
|
|
};
|
|
"<leader>la" = {
|
|
action = "code_action";
|
|
desc = "LSP Code [A]ctions";
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
};
|
|
}
|