summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 869659a)
raw | patch | inline | side by side (parent: 869659a)
author | Junio C Hamano <junkio@cox.net> | |
Thu, 13 Jul 2006 06:00:46 +0000 (23:00 -0700) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Thu, 13 Jul 2006 06:00:46 +0000 (23:00 -0700) |
We are trying to catch error condition of git-rev-list and cause
the downstream pack-objects to barf, but if you run rev-list
with anything that mucks with its stderr (such as GIT_TRACE),
any stderr output would cause the pipeline to fail.
[jc: originally from Matthias Lederhofer, with a reworded error message.]
Signed-off-by: Junio C Hamano <junkio@cox.net>
the downstream pack-objects to barf, but if you run rev-list
with anything that mucks with its stderr (such as GIT_TRACE),
any stderr output would cause the pipeline to fail.
[jc: originally from Matthias Lederhofer, with a reworded error message.]
Signed-off-by: Junio C Hamano <junkio@cox.net>
git-repack.sh | patch | blob | history |
diff --git a/git-repack.sh b/git-repack.sh
index 640ad8d90b9a9afd00506a9697af1d3e560e1255..9da92fb06139dc53061876f1532d9ee8c46d5346 100755 (executable)
--- a/git-repack.sh
+++ b/git-repack.sh
;;
esac
pack_objects="$pack_objects $local $quiet $no_reuse_delta$extra"
-name=$(git-rev-list --objects --all $rev_list 2>&1 |
+name=$( { git-rev-list --objects --all $rev_list ||
+ echo "git-rev-list died with exit code $?"
+ } |
git-pack-objects --non-empty $pack_objects .tmp-pack) ||
exit 1
if [ -z "$name" ]; then