Merge pull request #2899 from bennofs/nix-prefetch-revision
nix-prefetch-*: print fetched revision
This commit is contained in:
commit
5a44c0a7ce
@ -52,6 +52,8 @@ if test -z "$finalPath"; then
|
||||
# Perform the checkout.
|
||||
bzr -Ossl.cert_reqs=none export $revarg --format=dir "$tmpFile" "$url"
|
||||
|
||||
echo "bzr revision is $(bzr revno $revarg "$url")"
|
||||
|
||||
# Compute the hash.
|
||||
hash=$(nix-hash --type $hashType $hashFormat $tmpFile)
|
||||
if ! test -n "$QUIET"; then echo "hash is $hash" >&2; fi
|
||||
|
@ -217,7 +217,7 @@ clone_user_rev() {
|
||||
fi;;
|
||||
esac
|
||||
|
||||
echo "git revision is $(cd $dir && git rev-parse $rev)"
|
||||
echo "git revision is $(cd $dir && (git rev-parse $rev 2> /dev/null || git rev-parse refs/heads/fetchgit) | tail -n1)"
|
||||
|
||||
# Allow doing additional processing before .git removal
|
||||
eval "$NIX_PREFETCH_GIT_CHECKOUT_HOOK"
|
||||
|
@ -51,6 +51,7 @@ if test -z "$finalPath"; then
|
||||
hg archive -q -y -r "$rev" --cwd $tmpClone $tmpArchive
|
||||
rm -f $tmpArchive/.hg_archival.txt
|
||||
|
||||
echo "hg revision is $(cd $tmpClone; hg id -r "$rev" -i)"
|
||||
|
||||
# Compute the hash.
|
||||
hash=$(nix-hash --type $hashType $hashFormat $tmpArchive)
|
||||
|
@ -56,6 +56,7 @@ if test -z "$finalPath"; then
|
||||
fi
|
||||
|
||||
echo p | svn "$command" --quiet -r "$rev" "$url" "$tmpFile" >&2
|
||||
echo "svn revision is $(svn info -r "$rev" "$url" | grep "Revision: " | cut -d' ' -f2)"
|
||||
|
||||
# Compute the hash.
|
||||
hash=$(nix-hash --type $hashType $hashFormat $tmpFile)
|
||||
|
Loading…
Reference in New Issue
Block a user