Re: [PATCH 3/3] bisect: add --auto-reset to leave when done
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jul 16, 2026, 17:22 UTC
- Message-ID
- <xmqqse5ihmsz.fsf@gitster.g>
- In-Reply-To
- <a9194b1d00b260a7a7852eccec54c872618b5fdf.1784180159.git.gitgitgadget@gmail.com>
"Harald Nordgren via GitGitGadget" <gitgitgadget@gmail.com> writes:
> From: Harald Nordgren <haraldnordgren@gmail.com> > > When a bisection finished, "git bisect" reported the first bad commit > but left the session active until "git bisect reset" was run by hand.
If this gives an observation of the behavior of the current code, please write it in the present tense.
Show 5 quoted lines
> Add an "--auto-reset" option, accepted by both "git bisect start" and > "git bisect run", that resets as soon as the first bad commit is found, > returning to the commit checked out before "git bisect start". The flag > is persisted in a BISECT_AUTO_RESET state file and the restoring > checkout is done quietly.
I often find myself, after the culprit is found, running 'git reset --hard' or 'git bisect reset' to jump to the problematic commit to investigate further. If '--auto-reset' leaves me checked out on that bad commit, that would be a very welcome change. If it only returns me to where I started before the bisection, well, 'Meh'.