Re: [PATCH v6 4/4] history: re-edit a squash with every message
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jun 29, 2026, 05:50 UTC
- Message-ID
- <xmqqwlvhzyhz.fsf@gitster.g>
- In-Reply-To
- <4edf012b77fd2f2fb2a51eb10863bbf852fffa40.1782635349.git.gitgitgadget@gmail.com>
"Harald Nordgren via GitGitGadget" <gitgitgadget@gmail.com> writes:
Show 9 quoted lines
> From: Harald Nordgren <haraldnordgren@gmail.com> > > By default "git history squash" reuses the oldest commit's message. > When --reedit-message is given it only reopened that one message, so the > messages of the folded-in commits were lost. > > Gather the messages of every commit in the range, oldest first, and use > them as the editor template when re-editing, mirroring how "git rebase > -i" presents a squash.
I doubt it would make practical difference, but one thing I notice is that unlike "git rebase -i", this one does not intersperse markers like "# This is the 1st commit message" in between the messages taken from the squashed commits, so it is not exactly "mirroring".