From ffe4f66d431cc6039a1c66b0fefca4e94ee57095 Mon Sep 17 00:00:00 2001 From: Steven Allen Date: Thu, 13 Jan 2022 12:21:32 -0800 Subject: [PATCH] Avoid binding escape to bury-buffer and quit-window Escape usually means to: 1. Return to normal mode. 2. Abort the minibuffer. By binding it to quit-window (or equivalent), hitting escape a few times to exit a (potentially recursive) minibuffer, etc. can cause buffers to vanish. It's also: 1. Inconsistently applied. 2. Redundant with "q" (which is consistently applied). --- modes/magit/evil-collection-magit.el | 3 +-- modes/tetris/evil-collection-tetris.el | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/modes/magit/evil-collection-magit.el b/modes/magit/evil-collection-magit.el index 8087789..6964545 100644 --- a/modes/magit/evil-collection-magit.el +++ b/modes/magit/evil-collection-magit.el @@ -315,8 +315,7 @@ When this option is enabled, the stash popup is available on \"Z\"." (,states magit-mode-map ,(kbd "S-SPC") magit-diff-show-or-scroll-up "SPC") (,states magit-mode-map ,(kbd "S-DEL") magit-diff-show-or-scroll-down "DEL") - ((,evil-collection-magit-state) magit-mode-map ,(kbd evil-toggle-key) evil-emacs-state) - ((,evil-collection-magit-state) magit-mode-map ,(kbd "") magit-mode-bury-buffer)) + ((,evil-collection-magit-state) magit-mode-map ,(kbd evil-toggle-key) evil-emacs-state)) (if (eq evil-search-module 'evil-search) `((,states magit-mode-map "/" evil-ex-search-forward) diff --git a/modes/tetris/evil-collection-tetris.el b/modes/tetris/evil-collection-tetris.el index 9583cea..11962a4 100644 --- a/modes/tetris/evil-collection-tetris.el +++ b/modes/tetris/evil-collection-tetris.el @@ -49,8 +49,7 @@ "p" 'tetris-pause-game "q" 'quit-window "ZQ" 'quit-window - "ZZ" 'tetris-end-game - (kbd "") 'quit-window)) + "ZZ" 'tetris-end-game)) (provide 'evil-collection-tetris) ;;; evil-collection-tetris.el ends here