feat: some neovim customizaion
This commit is contained in:
parent
e2fab632ef
commit
39643701c8
10 changed files with 263 additions and 66 deletions
43
modules/nvim.nix
Normal file
43
modules/nvim.nix
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
{pkgs, ...}: {
|
||||
programs.nixvim = {
|
||||
enable = true;
|
||||
globals.mapleader = " ";
|
||||
|
||||
opts = {
|
||||
relativenumber = true;
|
||||
};
|
||||
|
||||
colorschemes.ayu.enable = true;
|
||||
|
||||
autoCmd = [
|
||||
{
|
||||
event = "BufWritePre";
|
||||
pattern = "*.nix";
|
||||
callback = {
|
||||
__raw = "function(args) require('conform').format({ bufnr = args.buf }) end";
|
||||
};
|
||||
}
|
||||
];
|
||||
|
||||
plugins.nix.enable = true;
|
||||
plugins.treesitter.enable = true;
|
||||
plugins.lspconfig.enable = true;
|
||||
plugins.blink-cmp.enable = true;
|
||||
plugins.telescope.enable = true;
|
||||
|
||||
plugins.conform-nvim = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
formatters_by_ft = {
|
||||
nix = ["alejandra"];
|
||||
};
|
||||
};
|
||||
};
|
||||
lsp.servers.nil_ls.enable = true;
|
||||
};
|
||||
|
||||
users.users.prever.packages = [
|
||||
pkgs.alejandra
|
||||
];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue