nixos/user/programs/neovim/default.nix
2024-03-18 12:58:34 +01:00

59 lines
1.2 KiB
Nix

{ pkgs, ... }: {
programs = {
neovim = {
enable = true;
defaultEditor = true;
vimAlias = true;
plugins = with pkgs.vimPlugins; [
vim-fugitive
undotree
telescope-nvim
nvim-cmp
cmp-nvim-lsp
nvim-lspconfig
lsp-zero-nvim
vim-floaterm
luasnip
cmp_luasnip
lualine-nvim
vim-sleuth
copilot-lua
copilot-cmp
cmp-cmdline
cmp-buffer
catppuccin-nvim
(nvim-treesitter.withPlugins (p: [
p.tree-sitter-yaml
p.tree-sitter-nix
p.tree-sitter-go
p.tree-sitter-lua
p.tree-sitter-vim
p.tree-sitter-bash
p.tree-sitter-json
p.tree-sitter-python
]))
];
extraLuaConfig = ''
${builtins.readFile ./options.lua}
${builtins.readFile ./plugins.lua}
${builtins.readFile ./keybinds.lua}
'';
};
};
home.packages = with pkgs; [
# nix stuff
nixpkgs-fmt
statix
# LSPs
gopls
nodePackages.pyright
nodePackages.typescript-language-server
nodePackages.typescript
nil
yaml-language-server
lua-language-server
];
home.sessionVariables.EDITOR = "nvim";
}