summaryrefslogtreecommitdiffstats
path: root/git-bisect.sh
diff options
context:
space:
mode:
authorSZEDER Gábor <szeder@ira.uka.de>2010-10-10 23:48:58 +0200
committerJunio C Hamano <gitster@pobox.com>2010-10-13 15:07:50 -0700
commit2c7c3877def8629278f5367a461ef269b0cfaa99 (patch)
tree847ce00156ec8ad098a96fc3cddbb3dcf2b084b1 /git-bisect.sh
parent3bb8cf88247db589b60e79c0520b081793cfd68e (diff)
downloadgit-2c7c3877def8629278f5367a461ef269b0cfaa99.tar.gz
git-2c7c3877def8629278f5367a461ef269b0cfaa99.tar.xz
bisect: check for mandatory argument of 'bisect replay'
'git bisect replay' has a mandatory logfile argument, but the current implementation doesn't check whether the user has specified one. When the user omits the logfile argument, this leads to the following unhelpful error message: cannot read for replaying So, check for the mandatory argument first, and provide a more meaningful error message when it is omitted. Signed-off-by: SZEDER Gábor <szeder@ira.uka.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-bisect.sh')
-rwxr-xr-xgit-bisect.sh1
1 files changed, 1 insertions, 0 deletions
diff --git a/git-bisect.sh b/git-bisect.sh
index 68fcff6db..c21e33c8d 100755
--- a/git-bisect.sh
+++ b/git-bisect.sh
@@ -343,6 +343,7 @@ bisect_clean_state() {
}
bisect_replay () {
+ test "$#" -eq 1 || die "No logfile given"
test -r "$1" || die "cannot read $1 for replaying"
bisect_reset
while read git bisect command rev