nix-config/users/tacocat/neovim/default.nix

91 lines
1.7 KiB
Nix

{
pkgs,
lib,
...
}: {
programs.nixvim = {
enable = true;
colorschemes.nord = {
enable = true;
borders = true;
contrast = true;
};
clipboard = {
providers.wl-copy.enable = true;
register = "unnamedplus";
};
extraPackages = with pkgs; [
latexrun
zathura
];
options = {
number = true;
relativenumber = true;
tabstop = 2;
shiftwidth = 2;
expandtab = false;
scrolloff = 5;
autoindent = true;
smartindent = true;
copyindent = true;
signcolumn = "yes";
cursorline = true;
showmode = false;
};
plugins = {
lightline = {
enable = true;
colorscheme = "nord";
};
gitsigns = {
enable = true;
};
treesitter = {
enable = true;
nixvimInjections = true;
indent = true;
disabledLanguages = [
"latex"
];
ignoreInstall = [
"latex"
];
};
vimtex = {
enable = true;
texlivePackage = pkgs.texliveFull;
settings = {
compiler_method = "latexrun";
view_method = "zathura";
};
};
};
files = {
"ftplugin/nix.lua" = {
options = {
expandtab = true;
shiftwidth = 2;
tabstop = 2;
};
};
"ftplugin/markdown.lua" = {
options = {
spell = true;
};
};
"ftplugin/tex.lua" = {
options = {
spell = true;
};
};
};
keymaps = [
{
action = "<cmd>nohl<CR>";
key = "<C-q>";
options.silent = true;
}
];
};
}