bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#18: Fine-grained revert-buffer


From: Mauro Aranda
Subject: bug#18: Fine-grained revert-buffer
Date: Sat, 27 Apr 2019 14:46:50 -0300

Eli Zaretskii <eliz@gnu.org> writes:

> Is there a requirement to be able to undo the revert piecemeal? What
> would be the use case for that?

Your questions made me open my eyes, so thanks.  I originally thought
that it would be a good thing, for example if the user wants to revert some
of the changes but keep others.  But that use case is already covered by
using diff-buffer-with-file, for example, and applying (or not) each hunk
separately.  Even better, the undo process doesn't have to be from
the Nth hunk to the 1st, in order.  So please, ignore what I said about
that problem, using replace-buffer-contents seems to be a great choice
to address this wishlist item.

>> I haven't timed it yet.  I didn't know if it would be considered good
>> enough, to time it.  For a week, I've been testing it manually with some
>> of the changes in the Emacs sources, and the experience has been
>> satisfactory.  Are there, by any chance, such tests for
>> replace-buffer-contents?
>
> You can find one in bug#31888.
>
> Also, this discussion:
>
>   http://lists.gnu.org/archive/html/help-gnu-emacs/2019-02/msg00000.html
>
> indicates that using JSON pretty-printer might produce a good test
> case.

Thanks.

I'll keep working on the potential fallback for replace-buffer-contents,
and report back when I feel I've made some progress.

Best regards,
Mauro.

reply via email to

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