aboutsummaryrefslogtreecommitdiff
path: root/git-bisect.sh
diff options
context:
space:
mode:
Diffstat (limited to 'git-bisect.sh')
-rwxr-xr-xgit-bisect.sh7
1 files changed, 6 insertions, 1 deletions
diff --git a/git-bisect.sh b/git-bisect.sh
index 3a4bf8150..68fcff6db 100755
--- a/git-bisect.sh
+++ b/git-bisect.sh
@@ -316,7 +316,12 @@ bisect_reset() {
*)
usage ;;
esac
- git checkout "$branch" -- && bisect_clean_state
+ if git checkout "$branch" -- ; then
+ bisect_clean_state
+ else
+ die "Could not check out original HEAD '$branch'." \
+ "Try 'git bisect reset <commit>'."
+ fi
}
bisect_clean_state() {