Files
dendritic/modules/programs/neovim.nix
T
2026-03-30 00:04:50 -05:00

78 lines
1.8 KiB
Nix

{ self, inputs, ... }: {
flake-file.inputs = {
nvf = {
url = "github:notashelf/nvf";
inputs.nixpkgs.follows = "nixpkgs";
};
};
perSystem = { system, pkgs, ... }: {
packages.my-neovim = (inputs.nvf.lib.neovimConfiguration {
inherit pkgs;
modules = [
{
config.vim = {
options = {
number = true;
relativenumber = true;
expandtab = true;
shiftwidth = 4;
tabstop = 4;
softtabstop = 4;
};
syntaxHighlighting = true;
# Enable custom theming options
theme.enable = true;
theme.name = "catppuccin";
theme.style = "mocha";
lazy = {
enable = true;
};
telescope = {
enable = true;
extensions = [
{
name = "fzf";
packages = [pkgs.vimPlugins.telescope-fzf-native-nvim];
setup = {fzf = {fuzzy = true;};};
}
];
};
# Enable Treesitter
treesitter = {
enable = true;
# grammars = [ "python" ];
};
lsp.enable = true;
languages = {
enableTreesitter = true;
enableFormat = true;
python = {
enable = true;
dap.enable = true;
format.type = [ "ruff" ];
};
};
keymaps = [
{
key = "<leader>m";
mode = "n";
silent = true;
action = ":make<CR>";
}
];
};
}
];
})
.neovim;
};
}