2020-01-12 15:17:17 -08:00
|
|
|
# When I'm stuck in the terminal or don't have access to Emacs, (neo)vim is my
|
|
|
|
# go-to. I am a vimmer at heart, after all.
|
2019-08-06 10:56:54 -07:00
|
|
|
|
2020-03-28 22:48:43 -07:00
|
|
|
{ config, options, lib, pkgs, ... }:
|
2020-10-01 15:46:04 -07:00
|
|
|
|
2020-03-28 22:48:43 -07:00
|
|
|
with lib;
|
2020-10-01 15:46:04 -07:00
|
|
|
with lib.my;
|
|
|
|
let cfg = config.modules.editors.vim;
|
|
|
|
in {
|
2020-03-28 22:48:43 -07:00
|
|
|
options.modules.editors.vim = {
|
2020-10-01 15:46:04 -07:00
|
|
|
enable = mkBoolOpt false;
|
2020-03-28 22:48:43 -07:00
|
|
|
};
|
2020-01-12 17:42:33 -08:00
|
|
|
|
2020-10-01 15:46:04 -07:00
|
|
|
config = mkIf cfg.enable {
|
|
|
|
user.packages = with pkgs; [
|
|
|
|
editorconfig-core-c
|
|
|
|
neovim
|
|
|
|
];
|
|
|
|
|
2020-10-14 10:48:38 -07:00
|
|
|
# This is for non-neovim, so it loads my nvim config
|
2020-10-01 15:46:04 -07:00
|
|
|
# env.VIMINIT = "let \\$MYVIMRC='\\$XDG_CONFIG_HOME/nvim/init.vim' | source \\$MYVIMRC";
|
2020-01-13 18:56:20 -08:00
|
|
|
|
2020-10-01 15:46:04 -07:00
|
|
|
environment.shellAliases = {
|
|
|
|
vim = "nvim";
|
|
|
|
v = "nvim";
|
2020-03-28 22:48:43 -07:00
|
|
|
};
|
2019-08-06 10:56:54 -07:00
|
|
|
};
|
|
|
|
}
|