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

Re: Using Origin hashes to improve rebase behavior

From
JWJohn Wiegley <johnw@boostpro.com>
Date
Feb 11, 2011, 05:26 UTC
Message-ID
<m2fwrvta4t.fsf@hermes.luannocracy.com>
In-Reply-To
<20110211044539.GA2071@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 21 quoted lines
> OK. That's certainly the conservative answer, and where we should start.
> But I wonder in practice how many times we'll hit all the criteria just
> right for this feature to kick in (i.e., a cherry pick or rebase with no
> conflicts, followed by one that would cause a conflict). But I think
> there's nothing to do but implement and see how it works.
>
> After thinking about this a bit more, the whole idea of "is this
> cherry-picked/rebased/whatever commit the same as the one before" is
> really the same as the notes-rewriting case (i.e., copying notes on
> commit A when it is rebased into A'). Which makes me excited about using
> notes for this, because the rules that you do figure out to work in
> practice will be good rules for notes rewriting in general.
>
>> The problem with an external annotation is that if developers are sharing
>> feature branches, as a branch maintainer I want to know whether commits coming
>> from those feature branches are already in the branch I'm maintaining.
>
> In that case, I would suggest putting it in git-notes and sharing the
> notes with each other. The notes code should happily merge them all
> together, and then everyone gets to see everybody else's
> cherry-pick/rebase annotations.

The more I've talked this over with my friend, the more we discover how difficult this is to get right in certain situations, and also how rare the actual use cases that require storage within the commit message are -- but at the same time, how valuable that information is when those cases occur!

This may be a bit more than I can chew right now, so thank you for bringing to my attention the depth of this problem. That's exactly why I posted here before beginning to punch out code that might solve just the naive cases. :)

Thanks, John
Previous: Jeff KingNext: Thomas Rast
Message 6 of 14 in “Using Origin hashes to improve rebase behavior”
  1. John WiegleyFeb 10, 2011
  2. Johan HerlandFeb 10, 2011
  3. Jeff KingFeb 10, 2011
  4. John WiegleyFeb 11, 2011
  5. Jeff KingFeb 11, 2011
  6. John WiegleyFeb 11, 2011
  7. Thomas RastFeb 12, 2011
  8. skillzero@gmail.comFeb 11, 2011
  9. Johan HerlandFeb 11, 2011
  10. Jeff KingFeb 11, 2011
  11. Junio C HamanoFeb 11, 2011
  12. Jeff KingFeb 11, 2011
  13. Enrico WeigeltFeb 20, 2011
  14. Dave AbrahamsFeb 21, 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.