From 2c935a63f7ae4616b7e7ccfd73c85fc223920b86 Mon Sep 17 00:00:00 2001 From: Magnar Sveen Date: Sun, 11 Aug 2013 16:27:52 +0200 Subject: [PATCH] Go to insert mode with `i` --- god-mode.el | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/god-mode.el b/god-mode.el index c3c8eef..86fac1f 100644 --- a/god-mode.el +++ b/god-mode.el @@ -81,6 +81,12 @@ :group 'god :type 'string) +(defcustom god-insert-key + "i" + "The key used to switch into insert mode." + :group 'god + :type 'string) + (defvar god-global-mode nil "Activate God mode on all buffers?") @@ -141,6 +147,8 @@ ;; Meta key support ((string= key god-meta-key) (god-mode-try-command "M-" "M-%s")) ((string= key (upcase god-meta-key)) (god-mode-try-command "C-M-" "C-M-%s")) + ;; Easy switch to insert mode + ((string= key god-insert-key) (god-local-mode -1)) ;; By default all other things are C-*/// (t (let* ((formatted (format "C-%s" key))