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

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

bug#49869: Revert buffer? Yes/No/Maybe


From: Lars Ingebrigtsen
Subject: bug#49869: Revert buffer? Yes/No/Maybe
Date: Fri, 06 Aug 2021 11:21:03 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Gregory Heytings <gregory@heytings.org> writes:

> Like this:
>
> (defcustom revert-buffer-short-answer nil "")
>
> (defun revert-buffer-short-answer (&optional ignore-auto noconfirm 
> preserve-modes)
>   (interactive (list (not current-prefix-arg)))
>   (if revert-buffer-short-answer
>       (let ((use-short-answers t)
>           (noconfirm (not (buffer-modified-p))))
>       (revert-buffer ignore-auto noconfirm preserve-modes))
>     (revert-buffer ignore-auto noconfirm preserve-modes)))
>
> (global-set-key (kbd "C-x x g") 'revert-buffer-short-answer)

Yes, something like that looks pretty nice.  But probably under a
different name (at least for the user option) to avoid confusion with
the `revert-buffer' command.

Uhm...  I have no ideas.  :-)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





reply via email to

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