mirror of https://github.com/wlcx/home.git
Start vim config
This commit is contained in:
parent
cec04d523c
commit
8bbc2c94c6
|
@ -4,7 +4,7 @@ let mypkgs = (import ../modules/pkgs.nix { inherit pkgs; });
|
|||
in {
|
||||
home.packages = mypkgs.all;
|
||||
home.sessionVariables = {
|
||||
"EDITOR" = "nvim";
|
||||
"EDITOR" = "vim";
|
||||
"WORDCHARS" = "\${WORDCHARS/\\/}"; # ctrl-w on paths without make angery
|
||||
};
|
||||
programs = {
|
||||
|
@ -16,7 +16,6 @@ in {
|
|||
shellAliases = {
|
||||
g = "git";
|
||||
cat = "bat";
|
||||
vim = "nvim";
|
||||
hmswitch = ''home-manager switch --flake ".#$(hostname -s)"'';
|
||||
nrswitch = "sudo nixos-rebuild switch --flake '.#'";
|
||||
};
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
dev = { ... }: {
|
||||
imports = [ ./default.nix ./git.nix ./macs.nix ./rust.nix ];
|
||||
imports = [ ./default.nix ./git.nix ./macs.nix ./rust.nix ./vim.nix ];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
# This module sets up a "full" neovim install with plugins and unicorns. It also
|
||||
# makes neovim the default editor and aliases vim to nvim.
|
||||
{ pkgs, ... }: {
|
||||
home.sessionVariables = { "EDITOR" = "nvim"; };
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
plugins = with pkgs.vimPlugins; [ vim-nix rust-vim ];
|
||||
extraConfig = ''
|
||||
set relativenumber
|
||||
let g:rustfmt_autosave = 1
|
||||
'';
|
||||
};
|
||||
programs.zsh.shellAliases = { vim = "nvim"; };
|
||||
}
|
Loading…
Reference in New Issue