emacs tip of the week #7: local chord shortcuts

I like chord-mode to avoid emacs pinkie.

If you want to bind say a quick double I to indent in python mode (and double U to unindent), do this:

(add-hook 'python-mode-hook '(lambda ()
                   (key-chord-define-local "II" 'python-indent-shift-right)
                   (key-chord-define-local "UU" 'python-indent-shift-left)))

 

Leave a Reply

Your email address will not be published. Required fields are marked *