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

Re: [BUG] multi-commit cherry-pick messes up the order of commits

From
Junio C Hamano <gitster@pobox.com>
Date
Jan 12, 2012, 18:41 UTC
Message-ID
<7v62gg3grq.fsf@alter.siamese.dyndns.org>
In-Reply-To
<20120112174731.GA6038@burratino>
Jonathan Nieder <jrnieder@gmail.com> writes:
Show 5 quoted lines
> Yes, exactly.  Another question: what should
>
> 	git cherry-pick master..next maint..master
>
> do?

Revision ranges are not defined as a union of sets, but a single set as a range between zero or more bottom (UNINTERESTING) commits and zero or more top commits, the ones reachable from the top but not from the bottom, so the above will work as if you said "^master ^maint master next", which is the same as "master..next" (if you assume all of "maint" is contained in "master" all of which is contained in "next", of course).

And it is not likely to change soon.

In the longer term (or in an alternate universe where we were inventing Git from scratch today without any existing users), we may want to revamp the revision machinery, taking advantage of the recent addition of the "cmdline" facility to it, so that we would walk ranges "master..next" and "maint..master" independently, clearing the object flags as needed between the separate traversals as needed, and then take a union of these ranges, before returning results from get_revision() calls.

Previous: Jonathan Nieder
Message 24 of 24 in “[BUG] multi-commit cherry-pick messes up the order of commits”
  1. SZEDER GáborJan 11, 2012
  2. Christian CouderJan 12, 2012
  3. SZEDER GáborJan 12, 2012
  4. Ramkumar RamachandraJan 12, 2012
  5. Jeff KingJan 12, 2012
  6. Ramkumar RamachandraJan 12, 2012
  7. Ramkumar RamachandraJan 12, 2012
  8. Jeff KingJan 12, 2012
  9. Ramkumar RamachandraJan 12, 2012
  10. cherry-pick: add failing test for out-of-order pickRamkumar Ramachandra, Jan 12, 2012
  11. Jonathan NiederJan 12, 2012
  12. cherry-pick: add failing test for out-of-order pickRamkumar Ramachandra, Jan 12, 2012
  13. Jonathan NiederJan 12, 2012
  14. Junio C HamanoJan 12, 2012
  15. Ramkumar RamachandraJan 12, 2012
  16. Jeff KingJan 12, 2012
  17. Jonathan NiederJan 12, 2012
  18. Jeff KingJan 12, 2012
  19. Junio C HamanoJan 12, 2012
  20. Johannes SixtJan 12, 2012
  21. Ramkumar RamachandraJan 12, 2012
  22. Jonathan NiederJan 12, 2012
  23. Jonathan NiederJan 12, 2012
  24. Junio C HamanoJan 12, 2012

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.