To install this package, run in Emacs:
M-x package-install RET devil RET
Devil mode trades your comma key in exchange for a modifier-free editing experience in Emacs. Yes, the comma key! The key you would normally wield for punctuation in nearly every corner of text. Yes, this is twisted! It would not be called the Devil otherwise, would it? If it were any more rational, we might call it something divine, like, uh, the God mode? But alas, there is nothing divine to be found here. Welcome, instead, to the realm of the Devil! You will be granted the occasional use of the comma key for punctuation, but only if you can charm the Devil. But beware, for in this sinister domain, you must relinquish your comma key and embrace an editing experience that whispers wicked secrets into your fingertips!
Devil is available in MELPA as well as NonGNU ELPA. If you are using
Emacs 28.1 or a more recent version of Emacs, you can get the latest
stable version of Devil by typing
M-x package-install RET devil RET.
Otherwise, you need to add MELPA or NonGNU ELPA to your list of
package archives and then install MELPA. More details on the
installation procedure is provided in the manual.
By default, Devil mode rebinds the comma key to activate Devil. Once activated, Devil reads a so-called Devil key sequence from you. As you type your Devil key sequence, Devil translates the key sequence to a regular Emacs key sequence. If any command is bound to the translated Emacs key sequence, Devil runs that command and then deactivates itself.
By default, each comma in the Devil key sequence is translated to "C-". For example, if you type ", x , f", Devil translates it to "C-x C-f". Similarly ", m" is translated to "M-". If you type ", m x", Devil translates it to "M-x". Further ", m m" is translated to "C-M-". If you type ", m m f" Devil translates it to "C-M-f". There are several other translations available in the default translation rules that let you enjoy working with Emacs while avoiding modifier keys. Further, the Devil activation key, translation rules, etc. are customisable. Thus if you do not like the default choices made in this package, you can customise it easily to suit your preferences.
Read the manual to learn how to install, use, and customise Devil.
To report bugs, suggest improvements, or ask questions, create issues.
Some amusing reactions to this project collected from various corners of the world wide web:
Every bit of this horrifies me, and I can't believe you've done it. Outstanding. Well done! – @kstrauser
This is insane. I am going to try it immediately. – @jrockway
Will defiantly check this out. – @strings
Defiantly! – @oantolin
, mnow translates to
, m znow translates to
, m ,now translates to
, m mnow translates to
, m m fchanged to
, m f.
, m m bchanged to
, m b.
, m m ychanged to
, m y.
, m m ^changed to
, m ^.
devil-set-keyto set a new Devil key and update the mode's keymap.
devil-versionsince it is useful in determining the source version conveniently. It helps during troubleshooting the package when installed from MELPA which sets the package version to a version derived from the current date and time.
devil-describe-keyto describe Devil key sequences.
devil-toggle-loggingto toggle logging.
, h , kto execute
, h , lto execute
devil-keyalso updates the mode's keymap.
local-function-key-mapand execute any command bound to the fallback key sequence. For example, when the Devil key sequence
, x <tab>is converted to
C-x <tab>, since no command is bound to this key sequence, it is further translated to
C-x TABand the command
indent-rigidlybound to it is executed.
isearch-modebecause typing special keys like
isearch-modeinserted the literal characters in the buffer as opposed to appending these characters to the search pattern. The default special key sequences now invoke
devil-execute-keyinstead which carefully look up the current binding for the current special key and executes it. This produces the correct behaviour of special keys even in
, <return>which was broken by the previous release of version 0.4.0.
devil-all-keys-repeatablethat makes all Devil key sequences repeatable when set to
, sto the default list of repeatable keys.
, dto the default list of repeatable keys.
, m m ^to the default list of repeatable keys.
mto support typing key sequences like
M-to support typing key sequences like
C-M-Vis translated to
, <backspace>, etc. For example, earlier
, <tab>translated to
C-TABand caused "undefined" error even if there was a command bound to
C-<tab>. With this fix,
, <tab>is now translated to
C-<tab>and invokes the command bound to it, if any.