Unverified Commit c90c292c authored by Austin Horstman's avatar Austin Horstman
Browse files

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: default avatarAustin Horstman <khaneliman12@gmail.com>
parent aa88b952
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -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;
  };

+5 −1
Original line number Diff line number Diff line
@@ -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 {