From: Phillip Wood Date: Sat, 18 Jul 2026 09:22:23 GMT Subject: Re: [PATCH 00/11] sequencer: do not record dropped commits as rewritten Message-ID: <82527cd3-b3b3-4cc6-80c6-b5833b262c83@gmail.com> In-Reply-To: Hi Uwe On 18/07/2026 09:37, Uwe Kleine-König wrote: > > While it works fine in my test case, it doesn't in my real-life > workflow. > > I have a big branch of changes that I maintain on top of next/master, on > todays rebase I experience: > > uwe@monoceros:~/gsrc/linux-2nd$ git rebase --onto=next-20260717 next-20260716 -r -i device_id^{} > ... handling commits that get empty using `git rebase --skip` ... > > uwe@monoceros:~/gsrc/linux-2nd$ git range-diff next-20260716..device_id next-20260717.. > ... > 24: 901ca5f67bc5 ! 24: 9f3e8813f6b4 mtd: nand-omap2: Move omap_nand_ids[] to raw nand driver > @@ Commit message > ## Notes ## > Forwarded: id:901ca5f67bc57219a9222115fabe1a1729b87e25.1784229863.git.ukleinek@kernel.org > > + Forwarded: id:20260716123646.1933293-2-u.kleine-koenig@baylibre.com > + > ## drivers/memory/omap-gpmc.c ## > @@ drivers/memory/omap-gpmc.c: static void __maybe_unused gpmc_read_timings_dt(struct device_node *np, > of_property_read_bool(np, "gpmc,time-para-granularity"); > 25: 69be5d4f9f13 < -: ------------ drm/radeon: Only define radeon_acpi_vfct_match when actually used > ... > > with: > > uwe@monoceros:~/gsrc/linux-2nd$ git notes show 69be5d4f9f13 > Forwarded: id:20260716123646.1933293-2-u.kleine-koenig@baylibre.com > > When I rebase without -i, the rebase happens without hitting empty > commits that I have to manually skip and then the notes for 69be5d4f9f13 > doesn't make it into the neighbour commit after rebase. > > So it seems there is still something fishy with interactive rebase. For historic reasons "-i" implies "--empty=ask", without "-i" the default "--empty=drop" (the UI is a mess). This patch series only stops commits that are dropped by "--empty=drop" from being recorded as rewritten, so it will only have an effect with "-i" if you add "--empty=drop". I'm still thinking about how to handle commits that are dropped by the user, for example when when they run "git rebase --skip" after a conflict, or they run "git rebase --continue" without committing after a commit that becomes empty with "--empty=ask". As an aside I really wish "--empty=ask" kept the empty commit on "git rebase --continue" and dropped it on "git rebase --skip" but the current behavior dates from the early days of git. Thanks Phillip