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

Re: How to combine multiple commit diffs?

From
Junio C Hamano <gitster@pobox.com>
Date
Oct 12, 2023, 17:03 UTC
Message-ID
<xmqqpm1jg4dk.fsf@gitster.g>
In-Reply-To
<CAOLTT8RzcENBx9NKffHReVKJAho89TCO7W2SPBX8sb2tEU84Gw@mail.gmail.com>
ZheNing Hu <adlternative@gmail.com> writes:
> This may seem similar to cherry-picking a few commits from a pile of
> commits, but in fact, we do not expect to actually perform
> cherry-picking.

If you said "We do not want to", I may be sympathetic, but it is curious that you said "We do not expect to", which hints that you already have some implementation in mind.

Whether you use a checkout of the history to a working tree and perform a series of "git cherry-pick" to implement it, or use the "git replay" machinery to perform them in-core, at the conceptual level, you would need to pick a base commit and apply the effect of those commits you would want to look at on top of that base in sequence, before you can see the combined change, no?

Puzzled.
Previous: ZheNing HuNext: ZheNing Hu
Message 2 of 5 in “How to combine multiple commit diffs?”
  1. ZheNing HuOct 12, 2023
  2. Junio C HamanoOct 12, 2023
  3. ZheNing HuOct 18, 2023
  4. Johannes SixtOct 12, 2023
  5. ZheNing HuOct 18, 2023

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.