git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #56191 from tobim/restrict-vim-update

Restrict vim update.py to generated.nix

commit34aa254f9ebf5899636a9927ceefbc9df80230f4 authorJörg Thalheim <Mic92@users.noreply.github.com> dateSun 3 Mar 2019, 22:12 (8 years ago) parent2e5c30c134a061
1 file changed+8−4
pkgs/misc/vim-plugins/update.py+8−4
pkgs/misc/vim-plugins/update.py+8−4
@@ -111,16 +111,20 @@ class Plugin:
111111 return copy
112112
113113
114−GET_PLUGINS = """(with import <localpkgs> {};
114+GET_PLUGINS = f"""(with import <localpkgs> {{}};
115115let
116+ inherit (vimUtils.override {{inherit vim;}}) buildVimPluginFrom2Nix;
117+ generated = callPackage {ROOT}/generated.nix {{
118+ inherit buildVimPluginFrom2Nix;
119+ }};
116120 hasChecksum = value: lib.isAttrs value && lib.hasAttrByPath ["src" "outputHash"] value;
117121 getChecksum = name: value:
118− if hasChecksum value then {
122+ if hasChecksum value then {{
119123 submodules = value.src.fetchSubmodules or false;
120124 sha256 = value.src.outputHash;
121125 rev = value.src.rev;
122− } else null;
123− checksums = lib.mapAttrs getChecksum vimPlugins;
126+ }} else null;
127+ checksums = lib.mapAttrs getChecksum generated;
124128in lib.filterAttrs (n: v: v != null) checksums)"""
125129
126130