Subject: bug#77580: [PATCH] New command ediff-undo

From: Michael Heerdegen <[email-masked]>
Date: Thu, 10 Apr 2025 16:42:58 +0200

Hello,

>   M-x vundo, m, b, d, q, C-x b *vundo-diff<TAB>.
>
> These ergonomics scale nicely when exploring undo histories, but for
> quick comparisons, they're hardly better than "fully manual" (copying
> to a temp buffer and doing diff-buffers).

My main concern is whether your proposed interface is really convenient.
Sure, vundo is for exploring, and requires hitting more keys.  But in my
experience, most of the time some exploration _is_ required: undo steps
are small or tiny, and later even may be amalgamated in a partly random
way.  So the problem is that often that the last undo step is not what
you think would be, and you don't know how far you must look back.  Then
you end up guessing or bisecting the prefix arg range.  Only to see that
it would have been easier to use a different method.

I don't say vundo is the optimal approach, but I would suggest to
experiment a bit to find out what is really helpful, before installing
anything.

As a start I find the idea of a separate "slave" buffer where one can
undo and redo without messing up the original buffer appealing.  I would
play back until the state I need stuff from or want to compare with, and
then invoke Ediff manually to copy the changes I want to restore.

Apart from that, something to visualize the latest undo history is
definitely useful, too.  But personally I would rather like to see
something like a popup displaying a chain (history) of poststamp like
diffs, or ediff like side-by-side views, and then clicking on them would
give me a diff or an Ediff session.  Wouldn't that be nice?

Michael.