mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-09 20:39:18 -08:00
vim: move to neovim
This commit is contained in:
parent
88721ea1cb
commit
31d35be90f
3 changed files with 32 additions and 57 deletions
|
|
@ -1,15 +1,16 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
home.sessionVariables.EDITOR = "vim";
|
||||
programs.vim = {
|
||||
home.sessionVariables.EDITOR = "nvim";
|
||||
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
settings = { };
|
||||
package = pkgs.vim_configurable-pynvim;
|
||||
#withPython3 = true;
|
||||
extraConfig = import ./vimrc.nix { inherit pkgs config; };
|
||||
vimAlias = true;
|
||||
viAlias = true;
|
||||
plugins = with pkgs.vimPlugins; [
|
||||
nerdtree
|
||||
vim-nix
|
||||
notmuch-vim
|
||||
rust-vim
|
||||
coc-nvim
|
||||
coc-rust-analyzer
|
||||
|
|
@ -27,33 +28,23 @@
|
|||
vim-lastplace
|
||||
base16-vim
|
||||
];
|
||||
#extraPackages = with pkgs;
|
||||
# [ (python3.withPackages (ps: with ps; [ black flake8 ])) ];
|
||||
#extraPython3Packages = (ps: with ps; [ jedi pylint ]);
|
||||
extraConfig = import ./vimrc.nix { inherit pkgs config; };
|
||||
};
|
||||
xdg.dataFile = {
|
||||
"vim/undo/.keep".text = "";
|
||||
"vim/swap/.keep".text = "";
|
||||
"vim/backup/.keep".text = "";
|
||||
};
|
||||
xdg.configFile = {
|
||||
"vim/coc/coc-settings.json".text = builtins.toJSON {
|
||||
"rust.rustfmt_path" = "${pkgs.rustfmt}/bin/rustfmt";
|
||||
"rust-analyzer.serverPath" = "rust-analyzer";
|
||||
"rust-analyzer.updates.prompt" = false;
|
||||
"rust-analyzer.notifications.cargoTomlNotFound" = false;
|
||||
"rust-analyzer.notifications.workspaceLoaded" = false;
|
||||
"rust-analyzer.procMacro.enable" = true;
|
||||
"rust-analyzer.cargo.loadOutDirsFromCheck" = true;
|
||||
"rust-analyzer.cargo-watch.enable" =
|
||||
true;
|
||||
"rust-analyzer.completion.addCallParenthesis" =
|
||||
false; # consider using this?
|
||||
"rust-analyzer.hoverActions.linksInHover" = true;
|
||||
"rust-analyzer.diagnostics.disabled" = [
|
||||
"inactive-code" # it has strange cfg support..?
|
||||
];
|
||||
coc = {
|
||||
enable = true;
|
||||
settings = {
|
||||
"rust.rustfmt_path" = "${pkgs.rustfmt}/bin/rustfmt";
|
||||
"rust-analyzer.serverPath" = "rust-analyzer";
|
||||
"rust-analyzer.updates.prompt" = false;
|
||||
"rust-analyzer.notifications.cargoTomlNotFound" = false;
|
||||
"rust-analyzer.notifications.workspaceLoaded" = false;
|
||||
"rust-analyzer.procMacro.enable" = true;
|
||||
"rust-analyzer.cargo.loadOutDirsFromCheck" = true;
|
||||
"rust-analyzer.cargo-watch.enable" = true;
|
||||
"rust-analyzer.completion.addCallParenthesis" = false; # consider using this?
|
||||
"rust-analyzer.hoverActions.linksInHover" = true;
|
||||
"rust-analyzer.diagnostics.disabled" = [
|
||||
"inactive-code" # it has strange cfg support..?
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue