summaryrefslogtreecommitdiff
path: root/git-bisect.sh
diff options
context:
space:
mode:
Diffstat (limited to 'git-bisect.sh')
-rwxr-xr-xgit-bisect.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/git-bisect.sh b/git-bisect.sh
index c58eea7cb6..d7518e9c3b 100755
--- a/git-bisect.sh
+++ b/git-bisect.sh
@@ -317,6 +317,16 @@ bisect_next() {
bad_commit=$(git show-branch $bad_rev)
echo "# first bad commit: $bad_commit" >>"$GIT_DIR/BISECT_LOG"
exit 0
+ elif test $res -eq 2
+ then
+ echo "# only skipped commits left to test" >>"$GIT_DIR/BISECT_LOG"
+ good_revs=$(git for-each-ref --format="--not %(objectname)" "refs/bisect/good-*")
+ for skipped in $(git rev-list refs/bisect/bad $good_revs)
+ do
+ skipped_commit=$(git show-branch $skipped)
+ echo "# possible first bad commit: $skipped_commit" >>"$GIT_DIR/BISECT_LOG"
+ done
+ exit $res
fi
# Check for an error in the bisection process