Add nixvim module to config basic option for neovim
This commit is contained in:
parent
07dcd7e606
commit
317a2b4a28
7 changed files with 259 additions and 25 deletions
|
|
@ -46,6 +46,7 @@
|
|||
};
|
||||
programs = {
|
||||
bash.enable = true;
|
||||
nixvim.enable = true;
|
||||
guix.enable = true;
|
||||
dae.enable = true;
|
||||
openssh.enable = true;
|
||||
|
|
|
|||
|
|
@ -28,5 +28,6 @@
|
|||
./obs.nix
|
||||
./sudo-rs.nix
|
||||
./garage.nix
|
||||
./nixvim
|
||||
];
|
||||
}
|
||||
|
|
|
|||
25
nixos/modules/programs/nixvim/default.nix
Normal file
25
nixos/modules/programs/nixvim/default.nix
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.nixvim;
|
||||
in {
|
||||
imports = [./option.nix];
|
||||
options = {
|
||||
youthlic.programs.nixvim = {
|
||||
enable = lib.mkEnableOption "nixvim";
|
||||
};
|
||||
};
|
||||
config = lib.mkIf cfg.enable {
|
||||
programs.nixvim = {
|
||||
enable = true;
|
||||
enableMan = true;
|
||||
colorschemes.gruvbox-material = {
|
||||
enable = true;
|
||||
autoLoad = true;
|
||||
};
|
||||
plugins.lualine.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
42
nixos/modules/programs/nixvim/option.nix
Normal file
42
nixos/modules/programs/nixvim/option.nix
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.nixvim;
|
||||
in {
|
||||
config = lib.mkIf cfg.enable {
|
||||
programs.nixvim = {
|
||||
opts = {
|
||||
backspace = ["indent" "eol" "start"];
|
||||
tabstop = 4;
|
||||
shiftwidth = 4;
|
||||
expandtab = true;
|
||||
shiftround = true;
|
||||
autoindent = true;
|
||||
nu = true;
|
||||
rnu = true;
|
||||
wildmenu = true;
|
||||
hlsearch = false;
|
||||
ignorecase = true;
|
||||
smartcase = true;
|
||||
completeopt = ["menu" "noselect"];
|
||||
cursorline = true;
|
||||
termguicolors = true;
|
||||
signcolumn = "yes";
|
||||
autoread = true;
|
||||
title = true;
|
||||
swapfile = false;
|
||||
backup = false;
|
||||
updatetime = 50;
|
||||
mouse = "a";
|
||||
undofile = true;
|
||||
exrc = true;
|
||||
scrolloff = 5;
|
||||
wrap = true;
|
||||
splitright = true;
|
||||
splitbelow = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -12,6 +12,7 @@
|
|||
disko.nixosModules.disko
|
||||
lix-module.nixosModules.default
|
||||
chaotic.nixosModules.default
|
||||
nixvim.nixosModules.nixvim
|
||||
|
||||
./..
|
||||
];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue