summary refs log tree commit diff stats
path: root/user/emacs
diff options
context:
space:
mode:
authorAlan Pearce2023-03-24 07:27:44 +0100
committerAlan Pearce2023-03-24 07:27:44 +0100
commit85aed2343af26b278eb8254846554881f8e35330 (patch)
tree58ef29de02c38ebb6a21ef691ca3bfb2812fb057 /user/emacs
parent0c6a0388c832b33cefd1e62676a8f14cfe8bbf21 (diff)
downloadnixfiles-85aed2343af26b278eb8254846554881f8e35330.tar.lz
nixfiles-85aed2343af26b278eb8254846554881f8e35330.tar.zst
nixfiles-85aed2343af26b278eb8254846554881f8e35330.zip
emacs: sest up evil-embrace hooks more nicely
Diffstat (limited to 'user/emacs')
-rw-r--r--user/emacs/init.el10
1 files changed, 5 insertions, 5 deletions
diff --git a/user/emacs/init.el b/user/emacs/init.el
index b8d8d863..bb59c2aa 100644
--- a/user/emacs/init.el
+++ b/user/emacs/init.el
@@ -418,14 +418,14 @@ _p_rev       _u_pper              _=_: upper/lower       _r_esolve
 
 (use-package evil-embrace
   :after evil-surround
+  :ghook ('LaTex-mode-hook #'embrace-LaTeX-mode-hook)
+  :ghook ('org-mode-hook #'embrace-org-mode-hook)
+  :ghook ('ruby-mode-hook #'embrace-ruby-mode-hook)
+  :ghook ('emacs-lisp-mode-hook #'embrace-emacs-lisp-mode-hook)
   :config (progn
             (setq evil-embrace-show-help-p nil)
             (push ?\/ evil-embrace-evil-surround-keys)
-            (evil-embrace-enable-evil-surround-integration)
-            (add-hook 'LaTeX-mode-hook #'embrace-LaTeX-mode-hook)
-            (add-hook 'org-mode-hook #'embrace-org-mode-hook)
-            (add-hook 'ruby-mode-hook #'embrace-ruby-mode-hook)
-            (add-hook 'emacs-lisp-mode-hook #'embrace-emacs-lisp-mode-hook)))
+            (evil-embrace-enable-evil-surround-integration)))
 
 (use-package evil-commentary
   :after evil