2021-10-05 23:42:21 -07:00
|
|
|
{ pkgs, ... }:
|
2019-08-24 02:38:45 -07:00
|
|
|
let
|
2020-05-27 02:43:45 -07:00
|
|
|
vim-goyo = pkgs.vimUtils.buildVimPlugin {
|
|
|
|
|
name = "vim-goyo";
|
|
|
|
|
src = pkgs.fetchFromGitHub {
|
|
|
|
|
owner = "junegunn";
|
|
|
|
|
repo = "goyo.vim";
|
|
|
|
|
rev = "6b6ed2734084fdbb6315357ddcaecf9c8e6f143d";
|
|
|
|
|
sha256 = "1ywlz1hn54kxyp5q0angriaarimq7ys7m6sk6l4x8jr1g2yh0afz";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
|
2020-10-07 00:43:06 -07:00
|
|
|
vim-nix = pkgs.vimUtils.buildVimPlugin {
|
|
|
|
|
name = "vim-nix";
|
|
|
|
|
src = pkgs.fetchFromGitHub {
|
|
|
|
|
owner = "LnL7";
|
|
|
|
|
repo = "vim-nix";
|
|
|
|
|
rev = "d733cb96707a2a6bdc6102b6d89f947688e0e959";
|
|
|
|
|
sha256 = "12k2gwm8b1n02361gpjhsldql99yd7qsh80a3lbwc5c5gz5j8jsb";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
|
2021-08-24 00:25:17 +00:00
|
|
|
vim-catppuccino = pkgs.vimUtils.buildVimPlugin {
|
|
|
|
|
name = "vim-catppuccino";
|
|
|
|
|
src = pkgs.fetchFromGitHub {
|
|
|
|
|
owner = "Pocco81";
|
|
|
|
|
repo = "Catppuccino.nvim";
|
|
|
|
|
rev = "014d8575acdd19ecef4ecb12fc82a2e21794b548";
|
|
|
|
|
sha256 = "0i0p21jkrx99n3dnm5xvnw8n963c67l4lgl4iwngz0psdzwxphkw";
|
|
|
|
|
};
|
|
|
|
|
};
|
2021-10-10 14:00:02 -07:00
|
|
|
in
|
|
|
|
|
with builtins;
|
2021-08-21 00:37:33 -07:00
|
|
|
{
|
2019-03-02 16:36:25 -08:00
|
|
|
programs.neovim = {
|
|
|
|
|
enable = true;
|
|
|
|
|
vimAlias = true;
|
2019-09-08 16:11:46 -07:00
|
|
|
plugins = with pkgs.vimPlugins; [
|
|
|
|
|
vim-sensible
|
|
|
|
|
vim-startify
|
2021-08-24 00:25:17 +00:00
|
|
|
vim-catppuccino
|
2020-12-18 17:03:27 -08:00
|
|
|
|
|
|
|
|
vim-elixir
|
2019-09-08 16:11:46 -07:00
|
|
|
alchemist-vim
|
2020-10-07 00:43:06 -07:00
|
|
|
vim-nix
|
2020-12-18 17:03:27 -08:00
|
|
|
vim-javascript
|
|
|
|
|
vim-json
|
|
|
|
|
vim-jsx-pretty
|
|
|
|
|
|
2021-08-20 21:35:48 -07:00
|
|
|
vim-commentary
|
2019-09-08 16:11:46 -07:00
|
|
|
vim-airline
|
2021-08-21 00:37:33 -07:00
|
|
|
{
|
|
|
|
|
plugin = rainbow;
|
|
|
|
|
config = ''
|
|
|
|
|
let g:rainbow_conf = {
|
|
|
|
|
\ 'guifgs': ['RoyalBlue3', 'SeaGreen3', 'DarkOrchid3', 'firebrick3', 'RoyalBlue3', 'SeaGreen3', 'DarkOrchid3', 'firebrick3', 'RoyalBlue3', 'DarkOrchid3', 'firebrick3', 'RoyalBlue3', 'SeaGreen3', 'DarkOrchid3', 'firebrick3'],
|
|
|
|
|
\ 'ctermfgs': ['red', 'brown', 'blue', 'gray', 'green', 'magenta', 'cyan', 'darkred', 'brown', 'darkblue', 'gray', 'darkgreen', 'darkmagenta', 'darkcyan', 'red'],
|
|
|
|
|
\ 'parentheses': ['start=/(/ end=/)/ fold', 'start=/\[/ end=/\]/ fold', 'start=/{/ end=/}/ fold']
|
|
|
|
|
\}
|
|
|
|
|
let g:rainbow_active = 1
|
2021-08-20 23:04:55 -07:00
|
|
|
'';
|
2021-08-21 00:37:33 -07:00
|
|
|
}
|
2019-09-08 16:11:46 -07:00
|
|
|
vim-signify
|
2021-08-24 00:25:17 +00:00
|
|
|
{
|
|
|
|
|
plugin = vim-indent-guides;
|
|
|
|
|
config = ''
|
|
|
|
|
let g:indent_guides_enable_on_vim_startup = 1
|
|
|
|
|
let g:indent_guides_start_level = 2
|
|
|
|
|
'';
|
|
|
|
|
}
|
2019-09-08 16:11:46 -07:00
|
|
|
vim-surround
|
|
|
|
|
fugitive
|
2021-08-21 00:37:33 -07:00
|
|
|
{
|
|
|
|
|
plugin = easymotion;
|
|
|
|
|
config = ''
|
|
|
|
|
map / <Plug>(easymotion-sn)
|
|
|
|
|
omap / <Plug>(easymotion-tn)
|
|
|
|
|
map n <Plug>(easymotion-next)
|
|
|
|
|
map N <Plug>(easymotion-prev)
|
|
|
|
|
let g:EasyMotion_landing_highlight = 0
|
2021-08-20 23:04:55 -07:00
|
|
|
'';
|
2021-08-21 00:37:33 -07:00
|
|
|
}
|
2019-09-08 16:11:46 -07:00
|
|
|
vinegar
|
|
|
|
|
undotree
|
2021-08-21 00:37:33 -07:00
|
|
|
{
|
|
|
|
|
plugin = nvim-compe;
|
|
|
|
|
config = ''
|
|
|
|
|
set completeopt=menuone,noselect
|
|
|
|
|
let g:compe = {}
|
|
|
|
|
let g:compe.enabled = v:true
|
|
|
|
|
let g:compe.autocomplete = v:true
|
|
|
|
|
let g:compe.debug = v:false
|
|
|
|
|
let g:compe.min_length = 1
|
|
|
|
|
let g:compe.preselect = 'enable'
|
|
|
|
|
let g:compe.throttle_time = 80
|
|
|
|
|
let g:compe.source_timeout = 200
|
|
|
|
|
let g:compe.resolve_timeout = 800
|
|
|
|
|
let g:compe.incomplete_delay = 400
|
|
|
|
|
let g:compe.max_abbr_width = 100
|
|
|
|
|
let g:compe.max_kind_width = 100
|
|
|
|
|
let g:compe.max_menu_width = 100
|
|
|
|
|
let g:compe.documentation = v:true
|
2021-08-20 23:04:55 -07:00
|
|
|
|
2021-08-21 00:37:33 -07:00
|
|
|
let g:compe.source = {}
|
|
|
|
|
let g:compe.source.path = v:true
|
|
|
|
|
let g:compe.source.buffer = v:true
|
|
|
|
|
let g:compe.source.calc = v:true
|
|
|
|
|
let g:compe.source.nvim_lsp = v:true
|
|
|
|
|
let g:compe.source.nvim_lua = v:true
|
|
|
|
|
let g:compe.source.vsnip = v:true
|
|
|
|
|
let g:compe.source.ultisnips = v:true
|
|
|
|
|
let g:compe.source.luasnip = v:true
|
|
|
|
|
let g:compe.source.emoji = v:true
|
2021-08-20 23:04:55 -07:00
|
|
|
'';
|
2021-08-21 00:37:33 -07:00
|
|
|
}
|
2020-05-27 02:43:45 -07:00
|
|
|
vim-goyo
|
2021-08-21 00:37:33 -07:00
|
|
|
{
|
|
|
|
|
plugin = nvim-lspconfig;
|
|
|
|
|
config = ''
|
2021-10-10 14:00:02 -07:00
|
|
|
lua << EOF
|
|
|
|
|
${readFile (
|
|
|
|
|
pkgs.substituteAll {
|
|
|
|
|
src = ./nvim-lspconfig.lua;
|
|
|
|
|
# since both of these are used for actually configuring the system,
|
|
|
|
|
# we'll probably always want them around.
|
|
|
|
|
lua_ls = pkgs.sumneko-lua-language-server;
|
|
|
|
|
rnix_lsp = pkgs.rnix-lsp;
|
|
|
|
|
}
|
|
|
|
|
) }
|
|
|
|
|
EOF
|
2021-08-20 23:04:55 -07:00
|
|
|
'';
|
2021-08-21 00:37:33 -07:00
|
|
|
}
|
2021-08-24 00:25:17 +00:00
|
|
|
{
|
|
|
|
|
plugin = telescope-nvim;
|
|
|
|
|
config = ''
|
|
|
|
|
nnoremap <leader>ff <cmd>lua require('telescope.builtin').find_files()<cr>
|
|
|
|
|
nnoremap <leader>fg <cmd>lua require('telescope.builtin').live_grep()<cr>
|
|
|
|
|
nnoremap <leader>fb <cmd>lua require('telescope.builtin').buffers()<cr>
|
|
|
|
|
nnoremap <leader>fh <cmd>lua require('telescope.builtin').help_tags()<cr>
|
|
|
|
|
'';
|
|
|
|
|
}
|
2019-09-08 16:11:46 -07:00
|
|
|
];
|
|
|
|
|
|
2021-10-05 23:42:21 -07:00
|
|
|
extraConfig = readFile ./init.vim;
|
2019-03-02 16:36:25 -08:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
}
|