Closed cofi closed 11 years ago
I don't know if it's related but I noticed this code doesn't enable global-evil-leader-mode
. In init.el (require-when-wished
is a function to require if the user says so or if el-get-package-is-installed
says yes):
(require-when-wished 'evil)
(eval-after-load 'evil
'(progn
(evil-mode 1)
(require-when-wished 'evil-leader)
(eval-after-load 'evil-leader
'(global-evil-leader-mode))))
If I replace '(global-evil-leader-mode)
by '(add-hook 'emacs-startup-hook 'global-evil-leader-mode)
, it works. I have recently switched from vimpulse
so I don't know if it's a bug or a misconception about this very welcome mode.
That's exactly the point I made above: With this layout you try to enable evil-leader-mode
before evil-local-mode
and global-evil-leader-mode
checks if evil-local-mode
is enabled to decide if evil-leader-mode
should be enabled, too.
For the time being you have to call global-evil-leader-mode
before evil-mode
to get it working, as confusing as it may be.
If
evil-mode
is enabled beforeglobal-evil-leader-mode
the order of the global enabler functions is wrong, resulting inevil-local-mode
being never enabled whenglobal-evil-leader-mode
checks.Workaround: Enable
global-evil-leader-mode
beforeevil-mode