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

Re: The case for two trees in a commit ("How to make rebase less modal")

From
Jeff King <peff@peff.net>
Date
Mar 1, 2018, 04:26 UTC
Message-ID
<20180301042620.GA21310@sigill.intra.peff.net>
In-Reply-To
<CAGZ79ka6PXgs+JDicaQYWYSKgEthj0A-2bBaRcdp_0T2H+sREA@mail.gmail.com>
On Wed, Feb 28, 2018 at 03:30:27PM -0800, Stefan Beller wrote:
Show 12 quoted lines
> During the rebase there might be a hard to resolve conflict, which
> you may not want to resolve right now, but defer to later.  Deferring a
> conflict is currently impossible, because precisely one tree is recorded.
> 
> If we had multiple trees possible in a commit, then all these large scale
> operations would stop being modal and you could just record the unresolved
> merge conflict instead; to come back later and fix it up later.
> 
> I'd be advocating for having multiple trees in a commit
> possible locally; it might be a bad idea to publish such trees.
> 
> Opinions or other use cases?

What benefit does it have over adding a new header "unresolved-tree" or similar? I do not think you are getting any backwards compatibility here. For instance, "prune" will not traverse it with existing versions of git, nor "pack-objects" include it in a pack (I didn't actually test it, so I could be wrong; but those are all based around parse_commit, which should look at only the first tree).

-Peff
Previous: Brandon WilliamsNext: Jacob Keller
Message 4 of 8 in “The case for two trees in a commit ("How to make rebase less modal")”
  1. Stefan BellerFeb 28, 2018
  2. Ramsay JonesMar 1, 2018
  3. Brandon WilliamsMar 1, 2018
  4. Jeff KingMar 1, 2018
  5. Jacob KellerMar 1, 2018
  6. Junio C HamanoMar 1, 2018
  7. Junio C HamanoMar 1, 2018
  8. Jonathan NiederMar 1, 2018

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.