[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#11977: 23.2; F5 and revert without confirmation
From: |
Dmitry Gutov |
Subject: |
bug#11977: 23.2; F5 and revert without confirmation |
Date: |
Thu, 19 Jul 2012 02:55:53 +0400 |
User-agent: |
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20120614 Thunderbird/13.0.1 |
"Drew Adams" <drew.adams@oracle.com> writes:
>> This piece of code should really be part of emacs defaults !
>>
>> (defun revert-buffer-no-confirm ()
>> "Revert buffer without confirmation."
>> (interactive) (revert-buffer t t))
>> (define-key global-map [f5] 'revert-buffer-no-confirm)
>
> +1, at least for adding the definition.
Personally, I don't think it's a good suggestion:
1. A user might stumble on the command accidentally (that's what the
confirmation is for).
2. (define-key global-map [f5] 'revert-buffer-no-confirm)
is not that much shorter than
(define-key global-map [f5] (lambda () (interactive) (revert-buffer t
t)))
--Dmitry