emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: master 4803fba487 1/2: 'C-x v v' on a diff buffer commits it as a pa


From: Lars Ingebrigtsen
Subject: Re: master 4803fba487 1/2: 'C-x v v' on a diff buffer commits it as a patch (bug#52349)
Date: Thu, 01 Sep 2022 12:16:07 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

Dmitry Gutov <dgutov@yandex.ru> writes:

>> Yes.  But I think you could just do that here, too?  I.e., instead
>> of
>> copying and managing files, you can just write the `C-x v D' diff to a
>> file, apply reverted diff, apply user-edited patch, commit, reverse
>> edited patch, apply diff from file.
>
> If you like, I can take this route as well. It seems a bit more
> error-prone, though: some unknown bug in diff-apply-hunk might make it
> fail at the end, or even corrupt the file contents silently.
>
> 'cp' seems more bullet-proof in that regard.

You should be able to get back to the previous state reliably by
reverting to the repository state and then applying the saved patch,
though.

Which is basically what git does with stashes, anyway...



reply via email to

[Prev in Thread] Current Thread [Next in Thread]