trivial-builders.nix: support directories in requireFile

Allow recursive hash for requireFile so it can support directories (#40568)
This commit is contained in:
Alexandre Esteves 2018-05-16 07:41:13 +01:00 committed by Matthew Justin Bauer
parent 4e891cf4d5
commit d273691f6d

View file

@ -138,6 +138,7 @@ rec {
, sha1 ? null
, url ? null
, message ? null
, hashMode ? "flat"
} :
assert (message != null) || (url != null);
assert (sha256 != null) || (sha1 != null);
@ -158,6 +159,7 @@ rec {
in
stdenv.mkDerivation {
name = name_;
outputHashMode = hashMode;
outputHashAlgo = hashAlgo;
outputHash = hash;
preferLocalBuild = true;