mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-18 19:03:28 +00:00
* Check the hash, but only on Nix <= 0.7.
svn path=/nixpkgs/trunk/; revision=2272
This commit is contained in:
parent
afc8ae625f
commit
4eba4a211e
@ -4,4 +4,12 @@ header "downloading $out from $url"
|
||||
|
||||
curl --fail --location --max-redirs 20 "$url" > "$out"
|
||||
|
||||
if test "$NIX_OUTPUT_CHECKED" != "1"; then
|
||||
actual=$(md5sum -b "$out" | cut -c1-32)
|
||||
if test "$actual" != "$md5"; then
|
||||
echo "hash is $actual, expected $md5"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
stopNest
|
||||
|
Loading…
Reference in New Issue
Block a user