nvim: move to services we do not specify a pkgset
This commit is contained in:
parent
465a6b19d1
commit
11b98d8146
45 changed files with 38 additions and 37 deletions
42
services/nvim.nix
Normal file
42
services/nvim.nix
Normal file
|
@ -0,0 +1,42 @@
|
|||
{
|
||||
lib,
|
||||
config,
|
||||
fn,
|
||||
nvim-lazy,
|
||||
...
|
||||
}:
|
||||
|
||||
with lib;
|
||||
{
|
||||
imports =
|
||||
[
|
||||
nvim-lazy.nixosModules.nvim-lazy
|
||||
]
|
||||
++ (fn.lst {
|
||||
path = (toString ./nvim);
|
||||
fullPath = true;
|
||||
});
|
||||
|
||||
programs.nvim-lazy = mkIf (elem "nvim" config.machine.pkgs) {
|
||||
enable = true;
|
||||
luaRcContent = # lua
|
||||
''
|
||||
vim.g.mapleader = " "
|
||||
vim.o.tabstop = 2
|
||||
vim.o.shiftwidth = 2
|
||||
vim.o.expandtab = true
|
||||
vim.o.ignorecase = true
|
||||
vim.o.smartcase = true
|
||||
vim.o.nrformats = alpha
|
||||
vim.bo.softtabstop = 2
|
||||
vim.wo.foldmethod = 'expr'
|
||||
vim.wo.foldexpr = 'nvim_treesitter#foldexpr()'
|
||||
vim.o.foldlevelstart = 99
|
||||
|
||||
vim.wo.number = true
|
||||
vim.wo.relativenumber = true
|
||||
|
||||
vim.o.scrolloff = 20
|
||||
'';
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue