Skip to content

Commit 6fe9c57

Browse files
chriscoolJunio C Hamano
authored andcommitted
Documentation: bisect: "start" accepts one bad and many good commits
Signed-off-by: Christian Couder <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 38a47fd commit 6fe9c57

File tree

1 file changed

+15
-4
lines changed

1 file changed

+15
-4
lines changed

Documentation/git-bisect.txt

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ DESCRIPTION
1515
The command takes various subcommands, and different options depending
1616
on the subcommand:
1717

18-
git bisect start [<paths>...]
18+
git bisect start [<bad> [<good>...]] [--] [<paths>...]
1919
git bisect bad <rev>
2020
git bisect good <rev>
2121
git bisect reset [<branch>]
@@ -134,15 +134,26 @@ $ git reset --hard HEAD~3 # try 3 revs before what
134134
Then compile and test the one you chose to try. After that, tell
135135
bisect what the result was as usual.
136136

137-
Cutting down bisection by giving path parameter to bisect start
138-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
137+
Cutting down bisection by giving more parameters to bisect start
138+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
139139

140140
You can further cut down the number of trials if you know what part of
141141
the tree is involved in the problem you are tracking down, by giving
142142
paths parameters when you say `bisect start`, like this:
143143

144144
------------
145-
$ git bisect start arch/i386 include/asm-i386
145+
$ git bisect start -- arch/i386 include/asm-i386
146+
------------
147+
148+
If you know beforehand more than one good commits, you can narrow the
149+
bisect space down without doing the whole tree checkout every time you
150+
give good commits. You give the bad revision immediately after `start`
151+
and then you give all the good revisions you have:
152+
153+
------------
154+
$ git bisect start v2.6.20-rc6 v2.6.20-rc4 v2.6.20-rc1 --
155+
# v2.6.20-rc6 is bad
156+
# v2.6.20-rc4 and v2.6.20-rc1 are good
146157
------------
147158

148159
Bisect run

0 commit comments

Comments
 (0)