autonix: allow one-to-many dependency resolution

This commit is contained in:
Thomas Tuegel 2015-03-08 17:28:44 -05:00
parent 32ee876647
commit afa4c3aed2

View File

@ -146,7 +146,11 @@ let
mkDerivation = drv: stdenv.mkDerivation (drv // { src = fetchurl drv.src; });
resolveDeps = scope: map (dep: scope."${dep}" or null);
resolveDeps = scope:
let resolveDeps_go = dep:
let res = scope."${dep}" or [];
in if isList res then res else [res];
in concatMap resolveDeps_go;
userEnvPkg = dep:
mapAttrs