git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] bisect reset: Allow resetting to any commit, not just a branch

From
Anders Kaseorg <andersk@mit.edu>
Date
Oct 12, 2009, 21:31 UTC
Message-ID
<alpine.DEB.2.00.0910121708030.5105@dr-wily.mit.edu>
In-Reply-To
<7vr5t8coex.fsf@alter.siamese.dyndns.org>
On Mon, 12 Oct 2009, Junio C Hamano wrote:
> I offhand do not see a good rationale for such a shortcut to finish 
> bisect and switch to another branch (IOW, I understand "it is shorter to 
> type", but I do not see "it is often done and very useful"), but I am 
> open to be enlightened by a workflow where such a shortcut is useful.

I agree that ‘git bisect reset <branch>’ is a confusing shortcut. It only really made sense before Git supported detached HEADs, and you needed to be on a branch all the time. I think that lifting the arbitrary restriction to branch names makes it less confusing, but if you want to remove the argument altogether, that would eliminate the confusion entirely.

I had in mind only one case where ‘git bisect reset <commit>’ would be useful. I often don’t even remember what commit I was on before I started a bisect, much less believe that I want to immediately switch back to it. I would prefer to be able to clean the bisection state without checking out another commit at all, because that takes forever and invalidates my compiled tree. This is what ‘git bisect reset HEAD’ would do if it worked.

Perhaps it makes sense to add a command that just clears the bisection state. ‘git bisect stop’?

Anders
Previous: Junio C HamanoNext: Junio C Hamano
Message 3 of 18 in “bisect reset: Allow resetting to any commit, not just a branch”
  1. bisect reset: Allow resetting to any commit, not just a branchAnders Kaseorg, Oct 12, 2009
  2. Junio C HamanoOct 12, 2009
  3. Anders KaseorgOct 12, 2009
  4. Junio C HamanoOct 12, 2009
  5. Johannes SixtOct 13, 2009
  6. Junio C HamanoOct 13, 2009
  7. Anders KaseorgOct 13, 2009
  8. bisect reset: Allow resetting to any commit, not just a branchAnders Kaseorg, Oct 13, 2009
  9. Christian CouderOct 13, 2009
  10. Anders KaseorgOct 13, 2009
  11. Christian CouderOct 13, 2009
  12. bisect reset: Allow resetting to any commit, not just a branchAnders Kaseorg, Oct 13, 2009
  13. Junio C HamanoOct 14, 2009
  14. Johannes SixtOct 13, 2009
  15. Junio C HamanoOct 13, 2009
  16. Johannes SixtOct 13, 2009
  17. Junio C HamanoOct 13, 2009
  18. Anders KaseorgOct 13, 2009

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.