-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathneovim.nix
146 lines (136 loc) · 4.03 KB
/
neovim.nix
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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
{ config, lib, pkgs, ... }:
let
my-vim-tweaks = pkgs.vimUtils.buildVimPlugin {
pname = "denisbueno-vim-config.vim";
version = "dev";
src = ./dotvim;
};
my-neovim-tweaks = pkgs.vimUtils.buildVimPlugin {
pname = "denisbueno-neovim-tweaks.vim";
version = "dev";
src = ./neovim;
};
my-vimoutliner = pkgs.vimUtils.buildVimPlugin rec {
pname = "vimoutliner";
version = "8c8b79700068482c6357626f2eae86fb68878d5b";
src = pkgs.fetchFromGitHub {
owner = "dbueno";
repo = "${pname}";
rev = "${version}";
sha256 = "8uD1dflyI8fn2rzk0l7aBHn6kOTGrpWKtsFv1p2oDXQ=";
};
};
synthwave84-nvim = pkgs.vimUtils.buildVimPlugin rec {
pname = "synthwave84";
version = "a5caa80d9e1a7021f9ec6c06a96d09dfc2d99ed1";
src = pkgs.fetchFromGitHub {
"owner" = "artanikin";
"repo" = "vim-synthwave84";
"rev" = "a5caa80d9e1a7021f9ec6c06a96d09dfc2d99ed1";
"hash" = "sha256-5+rOp2xDdtIMxMdvV0N18yTSQuSzYIfnFvwNeufaDgQ=";
};
};
tree-sitter-souffle-langston-barrett = pkgs.fetchFromGitHub {
owner = "langston-barrett";
repo = "tree-sitter-souffle";
rev = "901e71368a29d5f893d43d099fbc2b4ab037660e";
hash = "sha256-thUT+hi0lHnrpCuOe/bjlcM7ZfHruCDqN3YFOS3JCHA=";
};
nvim-treesitter-souffle-lyxell = pkgs.vimUtils.buildVimPlugin rec {
pname = "nvim-treesitter-souffle";
version = "81c0003447c61ee2c54aeea0f7ec934acf795061";
src = pkgs.fetchFromGitHub {
owner = "lyxell";
repo = "${pname}";
rev = "${version}";
hash = "sha256-qZ3gB14ojTjd50cU2lwB5bT8uwdJ1wVfnRysmxfG68E=";
};
};
souffle-treesitter-grammar = pkgs.tree-sitter.buildGrammar {
language = "souffle";
version = "901e7136";
src = tree-sitter-souffle-langston-barrett;
};
my-souffle-treesitter-grammar-src = pkgs.fetchFromGitHub {
owner = "dbueno";
repo = "tree-sitter-souffle";
rev = "f088865188e78cfdaf19581d890c94d79db8054b";
hash = "sha256-J9yH0dJYNDSmuA23vkz2WLWNhk80g8FqwgGp9qrmnzc=";
};
my-souffle-treesitter-grammar = pkgs.tree-sitter.buildGrammar {
language = "souffle";
version = "improve-preprocessor";
src = my-souffle-treesitter-grammar-src;
};
nvim-jdtls = pkgs.vimUtils.buildVimPlugin rec {
pname = "nvim-jdtls";
version = "efe813854432a314b472226dca813f0f2598d44a";
src = pkgs.fetchFromGitHub {
owner = "mfussenegger";
repo = "${pname}";
rev = "${version}";
hash = "sha256-r9qbunFJ62IqibVAdGbLsWSwYL53YKElLy98ArsK5V8=";
};
};
in {
nixpkgs.overlays = [
];
programs.neovim = {
enable = true;
defaultEditor = true;
vimAlias = true;
viAlias = true;
withRuby = false;
withPython3 = true;
plugins = [synthwave84-nvim nvim-jdtls] ++ (with pkgs.vimPlugins; [
tokyonight-nvim
my-vim-tweaks
my-neovim-tweaks
my-vimoutliner
vim-fugitive
vim-nix
vim-commentary
#tabular
vim-surround
securemodelines
editorconfig-vim
plenary-nvim
nvim-lspconfig
lsp_extensions-nvim
cmp-nvim-lsp
cmp-buffer
cmp-path
cmp-cmdline
nvim-cmp
lsp_signature-nvim
(nvim-treesitter.withPlugins (_: nvim-treesitter.allGrammars ++ [
my-souffle-treesitter-grammar
]))
nvim-treesitter-textobjects
cmp-vsnip
vim-vsnip
fzf-vim
]);
extraConfig = builtins.readFile ./config/nvim/vimrc
+ ''
set hidden
set smartcase
set ignorecase
set modeline
set number
set expandtab
set shiftwidth=2
set completeopt=menuone,noinsert,noselect
autocmd BufNewFile,BufRead *.dl setfiletype souffle
" lighten up theme comments
augroup my_colorschemes
au!
au Colorscheme dracula hi Comment guifg=#7c8ca8 ctermfg=69
au Colorscheme synthwave84 hi Comment guifg=#7c8ca8 ctermfg=69
au Colorscheme tokyonight hi Comment guifg=#7c8ca8 ctermfg=69
augroup END
colorscheme tokyonight-night
'';
extraLuaConfig = builtins.readFile ./config/nvim/init.lua;
};
}