home-manager/systems/common/nvim/default.nix

55 lines
1.2 KiB
Nix
Raw Normal View History

2023-08-26 16:35:30 +00:00
{pkgs, ...}: {
config.programs.neovim = {
enable = true;
2023-07-23 03:04:32 +00:00
2023-08-26 16:35:30 +00:00
defaultEditor = true;
viAlias = true;
vimAlias = true;
vimdiffAlias = true;
plugins = with pkgs.vimPlugins;
[
2023-07-23 03:04:32 +00:00
telescope-nvim # fuzzy finder
tokyonight-nvim # theme
undotree # undotree
vim-fugitive # git integration
nvim-treesitter # syntax highlighting
2023-08-26 16:35:30 +00:00
2023-07-23 03:04:32 +00:00
# Autocomplete and LSP
nvim-lspconfig
nvim-cmp
cmp-nvim-lsp
luasnip
2023-08-26 16:35:30 +00:00
]
++ (with pkgs.vimPlugins.nvim-treesitter-parsers; [
# Parsers for syntax highlighting
2023-07-23 03:04:32 +00:00
nix
zig
python
vim
vimdoc
markdown
dockerfile
yaml
json
toml
lua
c
glsl
bash
2023-08-26 16:35:30 +00:00
]);
extraPackages = [pkgs.nodePackages.pyright];
extraLuaConfig =
builtins.readFile ./keybinds.lua
+ builtins.readFile ./colors.lua
+ builtins.readFile ./undotree.lua
+ builtins.readFile ./fugitive.lua
+ builtins.readFile ./treesitter.lua
+ builtins.readFile ./telescope.lua
+ builtins.readFile ./cmp.lua
+ builtins.readFile ./lspconfig.lua;
extraConfig = "set number relativenumber";
};
2023-07-23 03:04:32 +00:00
}