diff options
author | Eric S. Raymond <esr@snark.thyrsus.com> | 1993-03-27 01:58:24 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@snark.thyrsus.com> | 1993-03-27 01:58:24 +0000 |
commit | b0912e2d9b3759d2e51ed7e23d1fe40c3325d717 (patch) | |
tree | 97663a7d0454c78101c4d0188f744c39c82a8548 /lisp/novice.el | |
parent | d91e2b1a2d91d9dd76754d4c639a5671fb0dd8e6 (diff) | |
download | emacs-b0912e2d9b3759d2e51ed7e23d1fe40c3325d717.tar.gz |
(enable-and-notify) Added. Inspired by Roland McGrath's LCD package
enable-me.
Diffstat (limited to 'lisp/novice.el')
-rw-r--r-- | lisp/novice.el | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lisp/novice.el b/lisp/novice.el index 2ddbbac3250..28ba34d206f 100644 --- a/lisp/novice.el +++ b/lisp/novice.el @@ -120,4 +120,13 @@ to future sessions." (insert "(put '" (symbol-name command) " 'disabled t)\n") (save-buffer))) +;;;###autoload +(defun enable-and-notify (&rest args) + "A novice hook for non-novices." + (put this-command 'disabled nil) + (message "You typed %s. %s was disabled. It's enabled now." + (key-description (this-command-keys)) this-command) + (sit-for 0) + (call-interactively this-command)) + ;;; novice.el ends here |