From 238642cb3b44350bb86d6db4c96fe2cbedb084b8 Mon Sep 17 00:00:00 2001 From: Howard Abrams Date: Mon, 10 Oct 2022 21:58:23 -0700 Subject: [PATCH] More evilness, including ESC for escape-quit --- ha-config.org | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/ha-config.org b/ha-config.org index d81843c..4b40ee4 100644 --- a/ha-config.org +++ b/ha-config.org @@ -379,10 +379,15 @@ Can we change Evil at this point? Some tips: evil-disable-insert-state-bindings t evil-want-keybinding nil evil-want-integration t + evil-want-C-u-scroll nil + evil-want-C-i-jump nil evil-escape-key-sequence "jk" evil-escape-unordered-key-sequence t) :config + ;; The Escape key act like C-g and always go back to normal mode? + (global-set-key (kbd "") 'keyboard-escape-quit) + ;; Underscores are part of a symbolic word in programming languages: ;; Sure, I could use capital `W' and `B', but I often forget that. (modify-syntax-entry ?_ "w") @@ -395,7 +400,18 @@ Can we change Evil at this point? Some tips: ;; In insert mode, type C-o to execute a single Evil command: (define-key evil-insert-state-map (kbd "C-o") 'evil-execute-in-normal-state) - (evil-mode)) + ;; Even with the `evil-collections' (see below), some modes should be Emacs: + (dolist (mode '(custom-mode + eshell-mode + git-rebase-mode + erc-mode + circe-server-mode + circe-chat-mode + circe-query-mode + vterm-mode)) + (add-to-list 'evil-emacs-state-modes mode) + + (evil-mode)) #+end_src While I’m pretty good with the VIM keybindings, I would like to play around with the [[https://evil.readthedocs.io/en/latest/extension.html#text-objects][text objects]] and how it compares to others (including the surround), for instance: