blob: e3bb02ef389e0a36ba499efe92c94da29567a15f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
|
{
config,
lib,
pkgs,
...
}: let
nvimConf = config.modules.desktop.apps.editors.neovim;
in {
options.modules.desktop.apps.editors.neovim = {
enable = lib.mkOption {
type = lib.types.bool;
default = false;
};
};
config = lib.mkIf (nvimConf.enable) {
modules.desktop.defaultApplications.apps.editor = rec {
package = pkgs.neovim;
install = false;
cmd = "${package}/bin/nvim";
desktop = "nvim";
};
home.packages = [
pkgs.nil
pkgs.texlab
pkgs.zls
pkgs.wgsl-analyzer
];
home.manager.programs.neovim = {
enable = true;
viAlias = true;
vimAlias = true;
withNodeJs = true;
extraConfig = ''
luafile ~/.config/nvim/lua/settings.lua
luafile ~/.config/nvim/lua/lsp.lua
'';
coc.enable = true;
coc.settings = {
"suggest.noselect" = true;
"suggest.enablePreview" = true;
"suggest.enablePreselect" = false;
"suggest.disableKind" = true;
"inlayHint.enable" = false;
"nix.enableLanguageServer" = true;
"nix.serverPath" = "nil";
"zig.enabled" = true;
"zig.path" = "${pkgs.zls}/bin/zls";
"languageserver" = {
"wgsl" = {
"command" = "${pkgs.wgsl-analyzer}/bin/wgsl-analyzer";
"filetypes" = [ "wgsl" ];
};
};
};
plugins = with pkgs.vimPlugins; [
nvim-web-devicons
gitsigns-nvim
catppuccin-nvim
vim-commentary
vim-fugitive
popup-nvim
plenary-nvim
telescope-nvim
wgsl-vim
nvim-lspconfig
nvim-treesitter nvim-treesitter.withAllGrammars
coc-clangd
coc-rust-analyzer
coc-lua
];
};
};
}
|