Restrict vim update.py to generated.nix
This commit is contained in:
parent
e5405f9ae8
commit
134a061d93
@ -111,16 +111,20 @@ class Plugin:
|
|||||||
return copy
|
return copy
|
||||||
|
|
||||||
|
|
||||||
GET_PLUGINS = """(with import <localpkgs> {};
|
GET_PLUGINS = f"""(with import <localpkgs> {{}};
|
||||||
let
|
let
|
||||||
|
inherit (vimUtils.override {{inherit vim;}}) buildVimPluginFrom2Nix;
|
||||||
|
generated = callPackage {ROOT}/generated.nix {{
|
||||||
|
inherit buildVimPluginFrom2Nix;
|
||||||
|
}};
|
||||||
hasChecksum = value: lib.isAttrs value && lib.hasAttrByPath ["src" "outputHash"] value;
|
hasChecksum = value: lib.isAttrs value && lib.hasAttrByPath ["src" "outputHash"] value;
|
||||||
getChecksum = name: value:
|
getChecksum = name: value:
|
||||||
if hasChecksum value then {
|
if hasChecksum value then {{
|
||||||
submodules = value.src.fetchSubmodules or false;
|
submodules = value.src.fetchSubmodules or false;
|
||||||
sha256 = value.src.outputHash;
|
sha256 = value.src.outputHash;
|
||||||
rev = value.src.rev;
|
rev = value.src.rev;
|
||||||
} else null;
|
}} else null;
|
||||||
checksums = lib.mapAttrs getChecksum vimPlugins;
|
checksums = lib.mapAttrs getChecksum generated;
|
||||||
in lib.filterAttrs (n: v: v != null) checksums)"""
|
in lib.filterAttrs (n: v: v != null) checksums)"""
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user