Move which-key footnote replacement to lisp/bandali-message.el.
authorAmin Bandali <bandali@gnu.org>
Sat, 25 Apr 2020 20:20:13 +0000 (16:20 -0400)
committerAmin Bandali <bandali@gnu.org>
Sat, 25 Apr 2020 20:20:13 +0000 (16:20 -0400)
Also, remove (use-package message-x).  Doesn't seem to be needed for
tab completion of Gcc in message.el.

init.el
lisp/bandali-message.el

diff --git a/init.el b/init.el
index a5fdea4..88cbc9b 100644 (file)
--- a/init.el
+++ b/init.el
@@ -960,8 +960,6 @@ Make N (default: 1) copies of the current line or region."
     "C-c t"   "themes")
 
   ;; prefixes for major modes
-  (which-key-add-major-mode-key-based-replacements 'message-mode
-    "C-c f n" "footnote")
   (which-key-add-major-mode-key-based-replacements 'org-mode
     "C-c C-v" "org-babel")
 
index ca30dc4..750188c 100644 (file)
 
 (use-package footnote
   :after message
-  ;; :config
+  :config
   ;; (setq footnote-start-tag ""
   ;;       footnote-end-tag   ""
   ;;       footnote-style     'unicode)
+  (when (featurep 'which-key)
+    (which-key-add-major-mode-key-based-replacements 'message-mode
+      "C-c f n" "footnote"))
   :bind
   (:map message-mode-map
         :prefix-map b/footnote-prefix-map
@@ -92,8 +95,6 @@
         ("r" . footnote-renumber-footnotes)
         ("s" . footnote-set-style)))
 
-(use-package message-x)
-
 (comment
   (use-package message-x
     :custom