[Carpet] git tip

Baiotti Luca baiotti at ea.c.u-tokyo.ac.jp
Tue Apr 22 07:25:07 CEST 2008


Dear carpet-git users,

I find the on-line git documentation partially unclear, so I share with 
you what I did to find the first patch that was "bad" (in the specific 
case, the first patch that broke the testsuites).

- go to the git tree directory

- run: git log

- in the output of the above command select a version that you think is 
"good" (i.e. still works); the version format is something like 
6b93d4531de10266355867d0d04e093b13aa8bda and follows the keyword 
"commit" in the above output

- run: git bisect start

- run: git bisect good 6b93d4531de10266355867d0d04e093b13aa8bda
	(for example)

- run: git bisect bad master

- this will make git remove half of the commits from the most recent 
version to version 6b93d4531de10266355867d0d04e093b13aa8bda

-* recompile your code and test it

-** if the test is OK, run: git bisect good
     if the test still fails, run: git bisect bad

- repeat steps * and ** until git tells you something like:

1dd96e20cb7a87d294c5298b46f01dff97b0da53 is first bad commit
commit 1dd96e20cb7a87d294c5298b46f01dff97b0da53
[...]

- you have found the first "bad" commit!

- [the following are words of the on-line documentation] You can then 
examine the commit with git-show(1), find out who wrote it, and mail 
them your bug report with the commit id

- in order to go back to the most recent version, run: git bisect reset


Ciao,

Luca


More information about the developers mailing list