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

Re: RFC: git bisect worktrees ../wk-A:../wk-B

From
Junio C Hamano <gitster@pobox.com>
Date
Mar 21, 2025, 08:19 UTC
Message-ID
<xmqqo6xuvlrs.fsf@gitster.g>
In-Reply-To
<CAJfuBxyUvvmevCC7bqLNJM-kTRVtMEhF4rSgf_1OQxezCOLSHg@mail.gmail.com>
jim.cromie@gmail.com writes:
Show 7 quoted lines
> hello all,
>
> it would be super convenient if git bisect was able
> to flip-flop between 2 (or more) worktrees while bisecting.
>
> This would leave both A, B in re-test-able states,
> allowing detailed forensics on the differences.

Many small questions come to mind, including "why two, not arbitrary N?".

A bit more constructively, I think you should be able to build the machinery around "git bisect --no-checkout". In "no-checkout" mode, the bisection machinery is used only to compute which one to try, and then you can update your own checkout you choose, which can span across multiple working trees.

And that machinery you'd build around "git bisect --no-checkout" would be the place to answer those many small questions like "you can use N worktrees round-robin fashion to keep the last N states for comparison---what should the value of N?".

> if this were a well-known feature, I could imagine that
> tools like rr would be enhanced to exploit it,

So, if you are planning to teach third-party tools and enhance them, the feature for them to exploit already exists, I would say, in the form of "bisect --no-checkout".

Previous: jim.cromie@gmail.com
Message 2 of 2 in “RFC: git bisect worktrees ../wk-A:../wk-B”
  1. jim.cromie@gmail.comMar 19, 2025
  2. Junio C HamanoMar 21, 2025

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.