Comply more with `writegood-mode'

This commit is contained in:
Gerard Vermeulen 2024-02-16 11:02:34 +01:00
parent b428de5668
commit 451321ce34

View File

@ -1182,10 +1182,10 @@ users from shooting themselves in the feet. Listing
(with-eval-after-load 'emacs (with-eval-after-load 'emacs
(setq disabled-command-function (setq disabled-command-function
(defun enable-this-command (&rest _args) (defun enable-this-command (&rest _args)
"Called when a disabled command is executed. "Called when executing a disabled command.
Enable it and re-execute it." Enable it and re-execute it."
(put this-command 'disabled nil) (put this-command 'disabled nil)
(message "You typed %s. %s was disabled until now." (message "You typed %s. Emacs enabled %s."
(key-description (this-command-keys)) this-command) (key-description (this-command-keys)) this-command)
(sit-for 0) (sit-for 0)
(call-interactively this-command)))) (call-interactively this-command))))