From e5d566ea2afe89cd026fe125d1e5c59d6558c636 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Sun, 12 May 2019 01:43:06 -0400 Subject: [PATCH] Prevent non-prefix key errors on doom//refresh May also help doom/reload --- core/autoload/cli.el | 7 ++++++- modules/editor/evil/config.el | 3 ++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/core/autoload/cli.el b/core/autoload/cli.el index 627a02147..693a31250 100644 --- a/core/autoload/cli.el +++ b/core/autoload/cli.el @@ -4,7 +4,10 @@ ;;;###autoload (defun doom-cli-run (command &rest _args) - (let* ((default-directory doom-emacs-dir) + (when (featurep 'general) + (general-auto-unbind-keys)) + (let* ((evil-collection-mode-list nil) + (default-directory doom-emacs-dir) (buf (get-buffer-create " *bin/doom*")) (doom-message-backend 'ansi) (ignore-window-parameters t) @@ -26,6 +29,8 @@ (redisplay) (doom-dispatch command nil) (print! (green "\nDone!")))) + (when (featurep 'general) + (general-auto-unbind-keys 'undo)) (message (format! (green "Done!")))) diff --git a/modules/editor/evil/config.el b/modules/editor/evil/config.el index cd0c3ade5..819880a5e 100644 --- a/modules/editor/evil/config.el +++ b/modules/editor/evil/config.el @@ -148,7 +148,8 @@ line with a linewise comment.") '+evil:align :move-point t :ex-arg 'buffer-match :ex-bang t :keep-visual t :suppress-operator t) ;; `evil-collection' - (when (featurep! +everywhere) + (when (and (featurep! +everywhere) + (not doom-reloading-p)) (load! "+everywhere")) ;; Custom evil ex commands