From 4956762039eb513231f7c8b62532fa6d14e11715 Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:31:56 -0500 Subject: [PATCH 01/12] vimPlugins.meson: move to non-generated Looks like it was missed in `overrides.nix` when it should be in non-generated. Signed-off-by: Austin Horstman --- .../vim/plugins/non-generated/meson/default.nix | 10 ++++++++++ pkgs/applications/editors/vim/plugins/overrides.nix | 7 ------- 2 files changed, 10 insertions(+), 7 deletions(-) create mode 100644 pkgs/applications/editors/vim/plugins/non-generated/meson/default.nix diff --git a/pkgs/applications/editors/vim/plugins/non-generated/meson/default.nix b/pkgs/applications/editors/vim/plugins/non-generated/meson/default.nix new file mode 100644 index 000000000000..53efe4a19200 --- /dev/null +++ b/pkgs/applications/editors/vim/plugins/non-generated/meson/default.nix @@ -0,0 +1,10 @@ +{ + lib, + vimUtils, + meson, +}: +vimUtils.buildVimPlugin { + inherit (meson) pname version src; + preInstall = "cd data/syntax-highlighting/vim"; + meta.maintainers = with lib.maintainers; [ vcunat ]; +} diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index 4942fbca8e09..85a856694d8b 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -33,7 +33,6 @@ languagetool, libgit2, llvmPackages, - meson, neovim-unwrapped, nim1, nodejs, @@ -1949,12 +1948,6 @@ in checkInputs = [ self.lualine-nvim ]; }; - meson = buildVimPlugin { - inherit (meson) pname version src; - preInstall = "cd data/syntax-highlighting/vim"; - meta.maintainers = with lib.maintainers; [ vcunat ]; - }; - mind-nvim = super.mind-nvim.overrideAttrs { dependencies = [ self.plenary-nvim ]; }; From 689e8e652fb56be0a2a93dd365928afc7dafcecc Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:35:33 -0500 Subject: [PATCH 02/12] vimPlugins.ethersync: move to non-generated Looks like it was missed in `overrides.nix` when it should be in non-generated. Signed-off-by: Austin Horstman --- .../plugins/non-generated/ethersync/default.nix | 14 ++++++++++++++ .../applications/editors/vim/plugins/overrides.nix | 13 ------------- 2 files changed, 14 insertions(+), 13 deletions(-) create mode 100644 pkgs/applications/editors/vim/plugins/non-generated/ethersync/default.nix diff --git a/pkgs/applications/editors/vim/plugins/non-generated/ethersync/default.nix b/pkgs/applications/editors/vim/plugins/non-generated/ethersync/default.nix new file mode 100644 index 000000000000..8e6f58e1a105 --- /dev/null +++ b/pkgs/applications/editors/vim/plugins/non-generated/ethersync/default.nix @@ -0,0 +1,14 @@ +{ + vimUtils, + ethersync, +}: +vimUtils.buildVimPlugin rec { + inherit (ethersync) + pname + version + src + meta + ; + + sourceRoot = "${src.name}/nvim-plugin"; +} diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index 85a856694d8b..e0aeef5ca345 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -133,8 +133,6 @@ # search-and-replace.nvim dependencies fd, sad, - # ethersync vim plugin - ethersync, }: self: super: let @@ -1159,17 +1157,6 @@ in ''; }; - ethersync = buildVimPlugin rec { - inherit (ethersync) - pname - version - src - meta - ; - - sourceRoot = "${src.name}/nvim-plugin"; - }; - executor-nvim = super.executor-nvim.overrideAttrs { dependencies = [ self.nui-nvim ]; }; From cfe8e54c1b77b9c3bc8941b2ab7b0b65ed126260 Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:35:45 -0500 Subject: [PATCH 03/12] vimPlugins.fzfWrapper: move to non-generated Looks like it was missed in `overrides.nix` when it should be in non-generated. Signed-off-by: Austin Horstman --- pkgs/applications/editors/vim/plugins/aliases.nix | 1 + .../plugins/non-generated/fzf-wrapper/default.nix | 14 ++++++++++++++ .../applications/editors/vim/plugins/overrides.nix | 13 +------------ 3 files changed, 16 insertions(+), 12 deletions(-) create mode 100644 pkgs/applications/editors/vim/plugins/non-generated/fzf-wrapper/default.nix diff --git a/pkgs/applications/editors/vim/plugins/aliases.nix b/pkgs/applications/editors/vim/plugins/aliases.nix index 1adb63ed5d23..0f4054d498e7 100644 --- a/pkgs/applications/editors/vim/plugins/aliases.nix +++ b/pkgs/applications/editors/vim/plugins/aliases.nix @@ -75,6 +75,7 @@ mapAliases ( feline-nvim = throw "feline.nvim has been removed: upstream deleted repository. Consider using lualine"; # Added 2025-02-09 fugitive = vim-fugitive; floating-nvim = throw "floating.nvim has been removed: abandoned by upstream. Use popup-nvim or nui-nvim"; # Added 2024-11-26 + fzfWrapper = fzf-wrapper; ghc-mod-vim = ghcmod-vim; ghcmod = ghcmod-vim; gleam-vim = throw "gleam.vim has been removed: its code was merged into vim."; # Added 2025-06-10 diff --git a/pkgs/applications/editors/vim/plugins/non-generated/fzf-wrapper/default.nix b/pkgs/applications/editors/vim/plugins/non-generated/fzf-wrapper/default.nix new file mode 100644 index 000000000000..c22afcf7e9ae --- /dev/null +++ b/pkgs/applications/editors/vim/plugins/non-generated/fzf-wrapper/default.nix @@ -0,0 +1,14 @@ +{ + vimUtils, + fzf, +}: +# Mainly used as a dependency for fzf-vim. Wraps the fzf program as a vim +# plugin, since part of the fzf vim plugin is included in the main fzf +# program. +vimUtils.buildVimPlugin { + inherit (fzf) src version; + pname = "fzf"; + postInstall = '' + ln -s ${fzf}/bin/fzf $target/bin/fzf + ''; +} diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index e0aeef5ca345..3ac1f9d4f6b8 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -1320,18 +1320,7 @@ in }; fzf-vim = super.fzf-vim.overrideAttrs { - dependencies = [ self.fzfWrapper ]; - }; - - # Mainly used as a dependency for fzf-vim. Wraps the fzf program as a vim - # plugin, since part of the fzf vim plugin is included in the main fzf - # program. - fzfWrapper = buildVimPlugin { - inherit (fzf) src version; - pname = "fzf"; - postInstall = '' - ln -s ${fzf}/bin/fzf $target/bin/fzf - ''; + dependencies = [ self.fzf-wrapper ]; }; gen-nvim = super.gen-nvim.overrideAttrs { From a15c556a0ff773819f0acd7b1332fde9fb5a717a Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:35:54 -0500 Subject: [PATCH 04/12] vimPlugins.hurl: move to non-generated Looks like it was missed in `overrides.nix` when it should be in non-generated. Signed-off-by: Austin Horstman --- .../vim/plugins/non-generated/hurl/default.nix | 11 +++++++++++ pkgs/applications/editors/vim/plugins/overrides.nix | 9 --------- 2 files changed, 11 insertions(+), 9 deletions(-) create mode 100644 pkgs/applications/editors/vim/plugins/non-generated/hurl/default.nix diff --git a/pkgs/applications/editors/vim/plugins/non-generated/hurl/default.nix b/pkgs/applications/editors/vim/plugins/non-generated/hurl/default.nix new file mode 100644 index 000000000000..7bb376ea1f18 --- /dev/null +++ b/pkgs/applications/editors/vim/plugins/non-generated/hurl/default.nix @@ -0,0 +1,11 @@ +{ + vimUtils, + hurl, +}: +vimUtils.buildVimPlugin { + pname = "hurl"; + inherit (hurl) version; + + # https://hurl.dev/ + src = "${hurl.src}/contrib/vim"; +} diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index 3ac1f9d4f6b8..bddaf8417f78 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -1474,15 +1474,6 @@ in dependencies = [ self.nui-nvim ]; }; - # https://hurl.dev/ - hurl = buildVimPlugin { - pname = "hurl"; - version = hurl.version; - # dontUnpack = true; - - src = "${hurl.src}/contrib/vim"; - }; - hurl-nvim = super.hurl-nvim.overrideAttrs { dependencies = with self; [ nui-nvim From 0858bbcc13b8242f8aaaaa42ac1f51981058711e Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:39:46 -0500 Subject: [PATCH 05/12] vimPlugins.minsnip-nvim: remove plugin Upstream repository removed. Signed-off-by: Austin Horstman --- pkgs/applications/editors/vim/plugins/aliases.nix | 1 + pkgs/applications/editors/vim/plugins/overrides.nix | 12 ------------ 2 files changed, 1 insertion(+), 12 deletions(-) diff --git a/pkgs/applications/editors/vim/plugins/aliases.nix b/pkgs/applications/editors/vim/plugins/aliases.nix index 0f4054d498e7..660fb8db03c1 100644 --- a/pkgs/applications/editors/vim/plugins/aliases.nix +++ b/pkgs/applications/editors/vim/plugins/aliases.nix @@ -95,6 +95,7 @@ mapAliases ( ipython = vim-ipython; latex-live-preview = vim-latex-live-preview; maktaba = vim-maktaba; + minsnip-nvim = throw "the upstream repository got deleted"; # added 2025-08-30 multiple-cursors = vim-multiple-cursors; necoGhc = neco-ghc; # backwards compat, added 2014-10-18 neocomplete = neocomplete-vim; diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index bddaf8417f78..b6e73c92fa61 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -1938,18 +1938,6 @@ in vimCommandCheck = "MinimapToggle"; }; - minsnip-nvim = buildVimPlugin { - pname = "minsnip.nvim"; - version = "2022-01-04"; - src = fetchFromGitHub { - owner = "jose-elias-alvarez"; - repo = "minsnip.nvim"; - rev = "6ae2f3247b3a2acde540ccef2e843fdfcdfebcee"; - sha256 = "1db5az5civ2bnqg7v3g937mn150ys52258c3glpvdvyyasxb4iih"; - }; - meta.homepage = "https://github.com/jose-elias-alvarez/minsnip.nvim/"; - }; - minuet-ai-nvim = super.minuet-ai-nvim.overrideAttrs { checkInputs = [ # optional cmp integration From 648fd98f24f173ae814e34c7eee2eab860a51ef6 Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:50:08 -0500 Subject: [PATCH 06/12] vimPlugins.phpactor: move to non-generated Looks like it was missed in `overrides.nix` when it should be in non-generated. Signed-off-by: Austin Horstman --- .../plugins/non-generated/phpactor/default.nix | 16 ++++++++++++++++ .../editors/vim/plugins/overrides.nix | 14 -------------- 2 files changed, 16 insertions(+), 14 deletions(-) create mode 100644 pkgs/applications/editors/vim/plugins/non-generated/phpactor/default.nix diff --git a/pkgs/applications/editors/vim/plugins/non-generated/phpactor/default.nix b/pkgs/applications/editors/vim/plugins/non-generated/phpactor/default.nix new file mode 100644 index 000000000000..107d6ca9c353 --- /dev/null +++ b/pkgs/applications/editors/vim/plugins/non-generated/phpactor/default.nix @@ -0,0 +1,16 @@ +{ + vimUtils, + phpactor, +}: +vimUtils.buildVimPlugin { + inherit (phpactor) + pname + src + meta + version + ; + postPatch = '' + substituteInPlace plugin/phpactor.vim \ + --replace-fail "g:phpactorpath = expand(':p:h') . '/..'" "g:phpactorpath = '${phpactor}'" + ''; +} diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index b6e73c92fa61..8cd54cbfcecd 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -40,7 +40,6 @@ openscad, openssh, parinfer-rust, - phpactor, ranger, ripgrep, skim, @@ -2969,19 +2968,6 @@ in ]; }; - phpactor = buildVimPlugin { - inherit (phpactor) - pname - src - meta - version - ; - postPatch = '' - substituteInPlace plugin/phpactor.vim \ - --replace-fail "g:phpactorpath = expand(':p:h') . '/..'" "g:phpactorpath = '${phpactor}'" - ''; - }; - plantuml-nvim = super.plantuml-nvim.overrideAttrs { dependencies = [ self.LibDeflate-nvim ]; }; From 4c8aa4257a925e62a8bb81332b56cc29d60610a4 Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:50:54 -0500 Subject: [PATCH 07/12] vimPlugins.skim: move to non-generated Looks like it was missed in `overrides.nix` when it should be in non-generated. Signed-off-by: Austin Horstman --- .../editors/vim/plugins/non-generated/skim/default.nix | 9 +++++++++ pkgs/applications/editors/vim/plugins/overrides.nix | 7 ------- 2 files changed, 9 insertions(+), 7 deletions(-) create mode 100644 pkgs/applications/editors/vim/plugins/non-generated/skim/default.nix diff --git a/pkgs/applications/editors/vim/plugins/non-generated/skim/default.nix b/pkgs/applications/editors/vim/plugins/non-generated/skim/default.nix new file mode 100644 index 000000000000..5fb2fcc5af57 --- /dev/null +++ b/pkgs/applications/editors/vim/plugins/non-generated/skim/default.nix @@ -0,0 +1,9 @@ +{ + vimUtils, + skim, +}: +vimUtils.buildVimPlugin { + pname = "skim"; + inherit (skim) version; + src = skim.vim; +} diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index 8cd54cbfcecd..55d387800e86 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -42,7 +42,6 @@ parinfer-rust, ranger, ripgrep, - skim, sqlite, sshfs, statix, @@ -3145,12 +3144,6 @@ in ]; }; - skim = buildVimPlugin { - pname = "skim"; - inherit (skim) version; - src = skim.vim; - }; - skim-vim = super.skim-vim.overrideAttrs { dependencies = [ self.skim ]; }; From e90c4fcba7fa3cf4afbe280e0d9368bbae12794b Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:51:36 -0500 Subject: [PATCH 08/12] vimPlugins.statix: move to non-generated Looks like it was missed in `overrides.nix` when it should be in non-generated. Signed-off-by: Austin Horstman --- .../plugins/non-generated/statix/default.nix | 17 +++++++++++++++++ .../editors/vim/plugins/overrides.nix | 15 --------------- 2 files changed, 17 insertions(+), 15 deletions(-) create mode 100644 pkgs/applications/editors/vim/plugins/non-generated/statix/default.nix diff --git a/pkgs/applications/editors/vim/plugins/non-generated/statix/default.nix b/pkgs/applications/editors/vim/plugins/non-generated/statix/default.nix new file mode 100644 index 000000000000..62dd5e9b9bc0 --- /dev/null +++ b/pkgs/applications/editors/vim/plugins/non-generated/statix/default.nix @@ -0,0 +1,17 @@ +{ + vimUtils, + statix, +}: +vimUtils.buildVimPlugin rec { + inherit (statix) pname src meta; + version = "0.1.0"; + postPatch = '' + # check that version is up to date + grep 'pname = "statix-vim"' -A 1 flake.nix \ + | grep -F 'version = "${version}"' + + cd vim-plugin + substituteInPlace ftplugin/nix.vim --replace-fail statix ${statix}/bin/statix + substituteInPlace plugin/statix.vim --replace-fail statix ${statix}/bin/statix + ''; +} diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index 55d387800e86..71b62430e031 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -44,7 +44,6 @@ ripgrep, sqlite, sshfs, - statix, stylish-haskell, tabnine, taskwarrior2, @@ -3260,20 +3259,6 @@ in dependencies = [ self.plenary-nvim ]; }; - statix = buildVimPlugin rec { - inherit (statix) pname src meta; - version = "0.1.0"; - postPatch = '' - # check that version is up to date - grep 'pname = "statix-vim"' -A 1 flake.nix \ - | grep -F 'version = "${version}"' - - cd vim-plugin - substituteInPlace ftplugin/nix.vim --replace-fail statix ${statix}/bin/statix - substituteInPlace plugin/statix.vim --replace-fail statix ${statix}/bin/statix - ''; - }; - stylish-nvim = super.stylish-nvim.overrideAttrs { postPatch = '' substituteInPlace lua/stylish/common/mouse_hover_handler.lua --replace-fail xdotool ${xdotool}/bin/xdotool From cfe364f05574835b226a9099202006c23333728b Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:52:50 -0500 Subject: [PATCH 09/12] vimPlugins.taskwarrior2: move to non-generated Looks like it was missed in `overrides.nix` when it should be in non-generated. Signed-off-by: Austin Horstman --- .../vim/plugins/non-generated/taskwarrior2/default.nix | 8 ++++++++ pkgs/applications/editors/vim/plugins/overrides.nix | 7 ------- 2 files changed, 8 insertions(+), 7 deletions(-) create mode 100644 pkgs/applications/editors/vim/plugins/non-generated/taskwarrior2/default.nix diff --git a/pkgs/applications/editors/vim/plugins/non-generated/taskwarrior2/default.nix b/pkgs/applications/editors/vim/plugins/non-generated/taskwarrior2/default.nix new file mode 100644 index 000000000000..0c9deecec1c0 --- /dev/null +++ b/pkgs/applications/editors/vim/plugins/non-generated/taskwarrior2/default.nix @@ -0,0 +1,8 @@ +{ + vimUtils, + taskwarrior2, +}: +vimUtils.buildVimPlugin { + inherit (taskwarrior2) version pname; + src = "${taskwarrior2.src}/scripts/vim"; +} diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index 71b62430e031..533b0eed18ec 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -46,7 +46,6 @@ sshfs, stylish-haskell, tabnine, - taskwarrior2, taskwarrior3, tmux, tup, @@ -3332,12 +3331,6 @@ in maintainers = with lib.maintainers; [ fredeb ]; }; }); - - taskwarrior2 = buildVimPlugin { - inherit (taskwarrior2) version pname; - src = "${taskwarrior2.src}/scripts/vim"; - }; - taskwarrior3 = buildVimPlugin { inherit (taskwarrior3) version pname; src = "${taskwarrior3.src}/scripts/vim"; From 37ffe2c9d410c1ddb27d78ef9e161b6400685118 Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:52:57 -0500 Subject: [PATCH 10/12] vimPlugins.taskwarrior3: move to non-generated Looks like it was missed in `overrides.nix` when it should be in non-generated. Signed-off-by: Austin Horstman --- .../vim/plugins/non-generated/taskwarrior3/default.nix | 8 ++++++++ pkgs/applications/editors/vim/plugins/overrides.nix | 6 ------ 2 files changed, 8 insertions(+), 6 deletions(-) create mode 100644 pkgs/applications/editors/vim/plugins/non-generated/taskwarrior3/default.nix diff --git a/pkgs/applications/editors/vim/plugins/non-generated/taskwarrior3/default.nix b/pkgs/applications/editors/vim/plugins/non-generated/taskwarrior3/default.nix new file mode 100644 index 000000000000..0abec7239e73 --- /dev/null +++ b/pkgs/applications/editors/vim/plugins/non-generated/taskwarrior3/default.nix @@ -0,0 +1,8 @@ +{ + vimUtils, + taskwarrior3, +}: +vimUtils.buildVimPlugin { + inherit (taskwarrior3) version pname; + src = "${taskwarrior3.src}/scripts/vim"; +} diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index 533b0eed18ec..d6f00e994604 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -46,7 +46,6 @@ sshfs, stylish-haskell, tabnine, - taskwarrior3, tmux, tup, typescript, @@ -3331,11 +3330,6 @@ in maintainers = with lib.maintainers; [ fredeb ]; }; }); - taskwarrior3 = buildVimPlugin { - inherit (taskwarrior3) version pname; - src = "${taskwarrior3.src}/scripts/vim"; - }; - telekasten-nvim = super.telekasten-nvim.overrideAttrs { dependencies = with self; [ plenary-nvim From aa88b95202fcfd930a22626bd67385c6ab54d890 Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 14:54:07 -0500 Subject: [PATCH 11/12] vimPlugins.tup: move to non-generated Looks like it was missed in `overrides.nix` when it should be in non-generated. Signed-off-by: Austin Horstman --- .../vim/plugins/non-generated/tup/default.nix | 21 +++++++++++++++++++ .../editors/vim/plugins/overrides.nix | 19 ----------------- 2 files changed, 21 insertions(+), 19 deletions(-) create mode 100644 pkgs/applications/editors/vim/plugins/non-generated/tup/default.nix diff --git a/pkgs/applications/editors/vim/plugins/non-generated/tup/default.nix b/pkgs/applications/editors/vim/plugins/non-generated/tup/default.nix new file mode 100644 index 000000000000..6a92e835a642 --- /dev/null +++ b/pkgs/applications/editors/vim/plugins/non-generated/tup/default.nix @@ -0,0 +1,21 @@ +{ + lib, + vimUtils, + tup, +}: +let + # Based on the comment at the top of https://github.com/gittup/tup/blob/master/contrib/syntax/tup.vim + ftdetect = builtins.toFile "tup.vim" '' + au BufNewFile,BufRead Tupfile,*.tup setf tup + ''; +in +vimUtils.buildVimPlugin { + inherit (tup) pname version src; + preInstall = '' + mkdir -p vim-plugin/syntax vim-plugin/ftdetect + cp contrib/syntax/tup.vim vim-plugin/syntax/tup.vim + cp "${ftdetect}" vim-plugin/ftdetect/tup.vim + cd vim-plugin + ''; + meta.maintainers = with lib.maintainers; [ enderger ]; +} diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index d6f00e994604..e51deb33832d 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -47,7 +47,6 @@ stylish-haskell, tabnine, tmux, - tup, typescript, typescript-language-server, vim, @@ -3587,24 +3586,6 @@ in dependencies = [ self.nvim-treesitter ]; }; - tup = - let - # Based on the comment at the top of https://github.com/gittup/tup/blob/master/contrib/syntax/tup.vim - ftdetect = builtins.toFile "tup.vim" '' - au BufNewFile,BufRead Tupfile,*.tup setf tup - ''; - in - buildVimPlugin { - inherit (tup) pname version src; - preInstall = '' - mkdir -p vim-plugin/syntax vim-plugin/ftdetect - cp contrib/syntax/tup.vim vim-plugin/syntax/tup.vim - cp "${ftdetect}" vim-plugin/ftdetect/tup.vim - cd vim-plugin - ''; - meta.maintainers = with lib.maintainers; [ enderger ]; - }; - typescript-nvim = super.typescript-nvim.overrideAttrs { checkInputs = [ # Optional null-ls integration From c90c292cef0253385a98c6157a853d3854dbdb27 Mon Sep 17 00:00:00 2001 From: Austin Horstman Date: Sat, 30 Aug 2025 15:09:47 -0500 Subject: [PATCH 12/12] vimPlugins: shadow plugin builders in overrides.nix We want to prevent plugins being added in `overrides.nix`. Shadow the helper names to throw if someone tries to add them and use them in the file. Signed-off-by: Austin Horstman --- pkgs/applications/editors/vim/plugins/default.nix | 1 - pkgs/applications/editors/vim/plugins/overrides.nix | 6 +++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/editors/vim/plugins/default.nix b/pkgs/applications/editors/vim/plugins/default.nix index 729129901315..0bf9f74f2ede 100644 --- a/pkgs/applications/editors/vim/plugins/default.nix +++ b/pkgs/applications/editors/vim/plugins/default.nix @@ -55,7 +55,6 @@ let # If additional modifications to the build process are required, # add to ./overrides.nix. overrides = callPackage ./overrides.nix { - inherit buildVimPlugin; inherit llvmPackages; }; diff --git a/pkgs/applications/editors/vim/plugins/overrides.nix b/pkgs/applications/editors/vim/plugins/overrides.nix index e51deb33832d..6baecc1ec162 100644 --- a/pkgs/applications/editors/vim/plugins/overrides.nix +++ b/pkgs/applications/editors/vim/plugins/overrides.nix @@ -3,7 +3,6 @@ stdenv, # nixpkgs functions buildGoModule, - buildVimPlugin, callPackage, fetchFromGitHub, fetchpatch, @@ -131,6 +130,11 @@ self: super: let luaPackages = neovim-unwrapped.lua.pkgs; + + # Ensure the vim plugin builders are not used in this file. + # If they are used, these stubs will throw. + buildVimPlugin = throw "New plugin definitions should be done outside `overrides.nix`"; + buildNeoVimPlugin = throw "New plugin definitions should be done outside `overrides.nix`"; in { corePlugins = symlinkJoin {