From: Jon Seymour Date: Thu, 4 Aug 2011 12:01:03 +0000 (+1000) Subject: bisect: add documentation for --no-checkout option. X-Git-Tag: v1.7.7-rc0~24^2~4 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=88d78911accc2b6c44732a1b6f6e9540c519d463;p=git.git bisect: add documentation for --no-checkout option. Signed-off-by: Jon Seymour Signed-off-by: Junio C Hamano --- diff --git a/Documentation/git-bisect.txt b/Documentation/git-bisect.txt index ab60a1847..41e6ca832 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 [ [...]] [--] [...] + git bisect start [--no-checkout] [ [...]] [--] [...] git bisect bad [] git bisect good [...] git bisect skip [(|)...] @@ -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 [ ... ] --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