2024-04-26 19:41:27 -06:00
|
|
|
{ pkgs, isUnstable, ... }:
|
2023-10-11 07:37:34 -06:00
|
|
|
with pkgs;
|
|
|
|
let
|
2023-12-01 14:27:57 -07:00
|
|
|
vimBuildTool = pkgs.vimUtils.buildVimPlugin;
|
2024-02-15 08:17:26 -07:00
|
|
|
|
2023-10-11 07:37:34 -06:00
|
|
|
vacme = vimBuildTool rec {
|
2022-10-26 10:19:10 -06:00
|
|
|
pname = "vacme";
|
2024-02-20 08:40:02 -07:00
|
|
|
# https://github.com/qbit/vacme
|
2022-10-26 10:19:10 -06:00
|
|
|
version = "2017-01-14";
|
|
|
|
src = pkgs.fetchFromGitHub {
|
2024-02-20 08:40:02 -07:00
|
|
|
owner = "qbit";
|
2022-10-26 10:19:10 -06:00
|
|
|
repo = pname;
|
2024-02-20 08:40:02 -07:00
|
|
|
rev = "3715958cc23195e0224efe4cb5ba5cfe129bd592";
|
|
|
|
hash = "sha256-vwqCa/iC01SY68seZ4/WarXDVjyi1FO5XHJglZr4l+8=";
|
2022-10-26 10:19:10 -06:00
|
|
|
};
|
|
|
|
};
|
2024-02-15 08:17:26 -07:00
|
|
|
|
2024-02-20 08:40:02 -07:00
|
|
|
nofrils = vimBuildTool rec {
|
|
|
|
pname = "nofrils";
|
|
|
|
version = "unstable-2020-10-08";
|
|
|
|
src = pkgs.fetchFromGitHub {
|
|
|
|
owner = "robertmeta";
|
|
|
|
repo = pname;
|
|
|
|
rev = "bad6e490846e098866136ef20fff31e99f428bb9";
|
|
|
|
hash = "sha256-BVBX2sFyTTqqgUmP0o77SKP1xrraJvCqkF+73rs0fLk=";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2024-04-26 19:41:27 -06:00
|
|
|
unstablePkgs = if isUnstable then [ htmx-lsp ] else [ ];
|
2022-08-25 12:21:35 -06:00
|
|
|
baseVimPackages = with vimPlugins; [
|
2023-03-28 14:21:27 -06:00
|
|
|
elm-vim
|
2022-08-25 12:21:35 -06:00
|
|
|
fugitive
|
2022-12-23 12:55:50 -07:00
|
|
|
fzf-vim
|
2024-03-07 07:17:34 -07:00
|
|
|
gleam-vim
|
2023-05-19 14:39:14 -06:00
|
|
|
haskell-vim
|
2023-07-11 13:16:57 -06:00
|
|
|
neoformat
|
2024-05-16 09:38:45 -06:00
|
|
|
neogit
|
2024-11-21 05:57:33 -07:00
|
|
|
nvim-cmp
|
2022-08-25 12:21:35 -06:00
|
|
|
nvim-lspconfig
|
2022-10-07 20:07:26 -06:00
|
|
|
nvim-tree-lua
|
2023-05-13 12:49:44 -06:00
|
|
|
nvim-treesitter.withAllGrammars
|
2022-10-07 20:07:26 -06:00
|
|
|
rust-vim
|
2023-01-04 13:31:51 -07:00
|
|
|
telescope-fzf-native-nvim
|
2023-06-05 14:05:38 -06:00
|
|
|
telescope-manix
|
2023-01-04 13:31:51 -07:00
|
|
|
telescope-nvim
|
2023-06-16 11:04:01 -06:00
|
|
|
todo-comments-nvim
|
2022-10-07 20:07:26 -06:00
|
|
|
vimagit
|
2022-08-25 12:21:35 -06:00
|
|
|
vim-gitgutter
|
2023-06-05 14:05:38 -06:00
|
|
|
vim-go
|
2023-05-19 14:39:14 -06:00
|
|
|
vim-hindent
|
2023-01-16 06:43:06 -07:00
|
|
|
vim-lua
|
2023-01-18 15:48:33 -07:00
|
|
|
vim-markdown
|
2022-08-25 12:21:35 -06:00
|
|
|
vim-nix
|
2022-10-08 06:06:57 -06:00
|
|
|
vim-ocaml
|
2023-05-01 14:37:38 -06:00
|
|
|
vim-sleuth
|
2022-08-25 12:21:35 -06:00
|
|
|
zig-vim
|
2022-10-26 10:19:10 -06:00
|
|
|
|
2023-01-23 17:30:06 -07:00
|
|
|
neogen
|
2022-10-26 10:19:10 -06:00
|
|
|
vacme
|
2024-02-20 08:40:02 -07:00
|
|
|
nofrils
|
2022-08-25 12:21:35 -06:00
|
|
|
];
|
2023-09-12 08:44:05 -06:00
|
|
|
myVimPackages = baseVimPackages;
|
|
|
|
in
|
|
|
|
{
|
2023-01-05 06:45:49 -07:00
|
|
|
environment.systemPackages = with pkgs; [
|
2024-04-29 21:15:24 -06:00
|
|
|
djlint
|
2023-03-28 14:21:27 -06:00
|
|
|
elmPackages.elm
|
|
|
|
elmPackages.elm-format
|
|
|
|
elmPackages.elm-language-server
|
2023-05-26 05:43:04 -06:00
|
|
|
fd
|
2023-01-16 06:43:06 -07:00
|
|
|
fzf
|
2023-01-05 06:45:49 -07:00
|
|
|
go
|
|
|
|
gopls
|
|
|
|
gotools
|
2023-05-19 14:39:14 -06:00
|
|
|
haskellPackages.haskell-language-server
|
|
|
|
haskellPackages.hindent
|
2023-01-16 06:43:06 -07:00
|
|
|
luaformatter
|
2023-03-28 14:21:27 -06:00
|
|
|
luajitPackages.lua-lsp
|
2023-01-05 06:45:49 -07:00
|
|
|
manix
|
2024-02-15 08:17:26 -07:00
|
|
|
nixpkgs-fmt
|
2023-05-26 05:43:04 -06:00
|
|
|
nodejs
|
2023-07-27 10:27:09 -06:00
|
|
|
nodePackages.prettier
|
2023-05-02 11:21:07 -06:00
|
|
|
nodePackages.typescript-language-server
|
2023-05-26 05:43:04 -06:00
|
|
|
perl
|
2024-02-15 08:17:26 -07:00
|
|
|
perlPackages.NeovimExt
|
2023-05-13 12:49:44 -06:00
|
|
|
perlPackages.PerlCritic
|
|
|
|
perlPackages.PLS
|
2023-01-16 06:43:06 -07:00
|
|
|
ripgrep
|
2023-01-18 05:37:39 -07:00
|
|
|
rubyPackages.solargraph
|
2024-02-15 08:17:26 -07:00
|
|
|
sleek
|
2023-05-02 11:21:07 -06:00
|
|
|
sumneko-lua-language-server
|
2023-05-26 05:43:04 -06:00
|
|
|
tree-sitter
|
2023-05-02 11:21:07 -06:00
|
|
|
zls
|
2024-04-26 19:41:27 -06:00
|
|
|
] ++ unstablePkgs;
|
2024-02-15 08:17:26 -07:00
|
|
|
|
2022-08-25 12:21:35 -06:00
|
|
|
programs.neovim = {
|
|
|
|
enable = true;
|
|
|
|
configure = {
|
2023-09-12 08:44:05 -06:00
|
|
|
packages.myVimPackage = { start = myVimPackages; };
|
2022-08-25 12:21:35 -06:00
|
|
|
customRC = ''
|
|
|
|
" Restore cursor position
|
|
|
|
autocmd BufReadPost *
|
|
|
|
\ if line("'\"") > 1 && line("'\"") <= line("$") |
|
|
|
|
\ exe "normal! g`\"" |
|
|
|
|
\ endif
|
|
|
|
|
|
|
|
luafile ${./neovim.lua}
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|