summaryrefslogtreecommitdiff
path: root/Documentation/git-bisect.txt
diff options
context:
space:
mode:
authorJon Seymour <jon.seymour@gmail.com>2011-08-04 22:01:03 +1000
committerJunio C Hamano <gitster@pobox.com>2011-08-04 15:37:38 -0700
commit88d78911accc2b6c44732a1b6f6e9540c519d463 (patch)
tree284b5e807520b689ead69a18d6ee81f77e99c0c0 /Documentation/git-bisect.txt
parentb704a8b3fd1d5a2eeeeadcef48c962db2c84b0af (diff)
downloadgit-88d78911accc2b6c44732a1b6f6e9540c519d463.tar.gz
bisect: add documentation for --no-checkout option.
Signed-off-by: Jon Seymour <jon.seymour@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/git-bisect.txt')
-rw-r--r--Documentation/git-bisect.txt32
1 files changed, 31 insertions, 1 deletions
diff --git a/Documentation/git-bisect.txt b/Documentation/git-bisect.txt
index ab60a18470..41e6ca832b 100644
--- a/Documentation/git-bisect.txt
+++ b/Documentation/git-bisect.txt
@@ -17,7 +17,7 @@ The command takes various subcommands, and different options depending
on the subcommand:
git bisect help
- git bisect start [<bad> [<good>...]] [--] [<paths>...]
+ git bisect start [--no-checkout] [<bad> [<good>...]] [--] [<paths>...]
git bisect bad [<rev>]
git bisect good [<rev>...]
git bisect skip [(<rev>|<range>)...]
@@ -263,6 +263,17 @@ rewind the tree to the pristine state. Finally the script should exit
with the status of the real test to let the "git bisect run" command loop
determine the eventual outcome of the bisect session.
+OPTIONS
+-------
+--no-checkout::
++
+Do not checkout the new working tree at each iteration of the bisection
+process. Instead just update a special reference named 'BISECT_HEAD' to make
+it point to the commit that should be tested.
++
+This option may be useful when the test you would perform in each step
+does not require a checked out tree.
+
EXAMPLES
--------
@@ -343,6 +354,25 @@ $ git bisect run sh -c "make || exit 125; ~/check_test_case.sh"
This shows that you can do without a run script if you write the test
on a single line.
+* Locate a good region of the object graph in a damaged repository
++
+------------
+$ git bisect start HEAD <known-good-commit> [ <boundary-commit> ... ] --no-checkout
+$ git bisect run sh -c '
+ GOOD=$(git for-each-ref "--format=%(objectname)" refs/bisect/good-*) &&
+ git rev-list --objects BISECT_HEAD --not $GOOD >tmp.$$ &&
+ git pack-objects --stdout >/dev/null <tmp.$$
+ rc=$?
+ rm -f tmp.$$
+ test $rc = 0'
+
+------------
++
+In this case, when 'git bisect run' finishes, bisect/bad will refer to a commit that
+has at least one parent whose reachable graph is fully traversable in the sense
+required by 'git pack objects'.
+
+
SEE ALSO
--------
link:git-bisect-lk2009.html[Fighting regressions with git bisect],