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

Re: [RFC/PATCH]: reverse bisect v 2.0

From
Junio C Hamano <gitster@pobox.com>
Date
Sep 30, 2011, 18:13 UTC
Message-ID
<7v62k9q4oq.fsf@alter.siamese.dyndns.org>
In-Reply-To
<20110930114220.GA742@zelva.suse.cz>

[administrivia: added people involved in the main discussion thread back on CC line, and also added CCouder who seems to be fond of the command]

Michal Vyskocil <mvyskocil@suse.cz> writes:
> The bugfix command works like the previous git bisect start --reverse.
Does any released version of git have "bisect start --reverse"?

$ git bisect start --reverse unrecognised option: '--reverse'

Let's suppose that we had a "git frotz" Porcelain subcommand, that used to say "xyzzy" when all is well, but says "nitfol" these days. I released a (bad) script that parses the output from the subcommand, and want to say something like "This script only works with Git version after X", and to find out the value of X, I need to bisect the history to find when "frotz" started to say "nitfol".

I am not trying to find a commit that introduced a bug/regression to cause the recent "frotz" to say "nitfol". Neither am I trying to find a fix that corrected the earlier bogus output "xyzzy". No value judgement is involved in this scenario.

I wonder if something along the following line would make the usage more pleasant and self-explanatory:

    $ git bisect start --used-to='git frotz says xyzzy' v0.99 master
    Bisecting: 171 revisions left to test after this (roughly 8 steps)
    $ ... build and then test ...
    $ git bisect tested
    You are trying to check: git frotz says xyzzy
    Does the result satisify what you are trying to find [y/n]? yes

Saying 'yes' would be like saying 'good' and 'no' would be like saying 'bad' here.

When trying to find regression, you would say:
    $ git bisect start --used-to='it works' v0.99 master

and you say 'yes' if it works (equivalent to 'good'), and 'no' if it does not (equivalent to 'bad').

When trying to find a fix, you would say:
    $ git bisect start --used-to='checkout $tree $path clobbers $path' v0.99 master

and you say 'yes' if it is still broken at the tested version (equivalent to your reversed 'good'), and 'no' if the tested version contains a fix (equivalent to your reversed 'bad').

I am not married to the name of the option, but --used-to='...' felt more or less self-explanatory name to signal users what to describe in that text. The condition "You are trying to check:" cue wants to remind the user is "we used to do *this* but now we don't", and the command is trying to see when it changed.

Thoughts?
Previous: Michal VyskocilNext: Jeff King
Message 8 of 17 in “RFC: reverse bisect”
  1. Michal VyskocilSep 29, 2011
  2. Sverre RabbelierSep 29, 2011
  3. Johannes SixtSep 29, 2011
  4. Jeff KingSep 30, 2011
  5. Frans KlaverSep 30, 2011
  6. Michal VyskocilSep 30, 2011
  7. : reverse bisect v 2.0Michal Vyskocil, Sep 30, 2011
  8. Junio C HamanoSep 30, 2011
  9. Jeff KingOct 3, 2011
  10. Junio C HamanoOct 3, 2011
  11. Jeff KingOct 4, 2011
  12. Junio C HamanoOct 4, 2011
  13. Christian CouderOct 4, 2011
  14. Junio C HamanoOct 4, 2011
  15. Andrew ArdillOct 7, 2011
  16. Junio C HamanoOct 12, 2011
  17. Jeff KingOct 12, 2011

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.