GNU bug report logs - #79408
31.0.50; VC commands for cherry-picking

Previous Next

Package: emacs;

Reported by: Sean Whitton <spwhitton <at> spwhitton.name>

Date: Mon, 8 Sep 2025 11:28:02 UTC

Severity: normal

Found in version 31.0.50

Full log


View this message in rfc822 format

From: Juri Linkov <juri <at> linkov.net>
To: Spencer Baugh <sbaugh <at> janestreet.com>
Cc: dmitry <at> gutov.dev, eliz <at> gnu.org, 79408 <at> debbugs.gnu.org, Sean Whitton <spwhitton <at> spwhitton.name>
Subject: bug#79408: 31.0.50; VC commands for cherry-picking
Date: Tue, 09 Sep 2025 21:01:36 +0300
>>> This reminded me of how we don't have a way to do format-patch using vc;
>>> that's somewhat related, and would be nice to support.
>>
>> We do!  'M-x vc-prepare-patch' is the interactive entry point.
>
> Ah, right.  I never use that because I always interact with Emacs
> development via Gnus, mostly via debbugs.el, and I just manually attach
> patches to my emails.  (debbugs.el also has some way to format a patch
> but I've never gotten it to work)

We still miss the command with a name like 'vc-attach-patch'
that would attach a marked revision to the current message.

>>> In fact, I wonder if perhaps:
>>>
>>> - a new format-patch backend function

The existing backend function 'prepare-patch' already uses
format-patch in 'vc-git-prepare-patch'.

> The VCS would still be (basically) handling the whole thing.  I'm
> suggesting that we basically just run:
>
> git format-patch | git am
>
> or:
>
> hg import | hg export
>
> Which (I think) is how cherry-picking works under the hood historically
> in git anyway.

Using backend commands to do the work would be more reliable.
Then as post-processing we need to update already visited buffers.




This bug report was last modified today.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.