git bisect
SafeBisect for the bad commit
git bisect start / good / bad
Binary-searches history for the breaking commit; 'bisect run <test>' automates the whole hunt.
Examples
git bisect run ./test.shAutomated bisect with a test
Syntax
git bisect start; git bisect bad; git bisect good <rev>
Before you run it
Finish with git bisect reset.
Related commands
- git logView history
- git switch / checkoutSwitch branch
- git reflogHEAD history (lifesaver)
The same reference, with no signal at all
Every command on this site, held on your device. The app adds 632 more: 1,510 commands and 120 fix flows, searchable with no connection. Free to install, no ads (some content is a one-time purchase).
Get it free on the App Store