Closed ashiklom closed 4 years ago
You cannot bind +evil/easymotion anywhere else but on evil-motion-state-map
, as it is by default:
(map! :leader :m "gs" #'evil/easymotion) ; note the :m
It was not designed to be bound anywhere else (and cannot be -- not reliably). It's a trick to lazy load evil-easymotion and then bind evilem-map to the key sequence that triggered it, without compromising which-key integration and without having to duplicate the built-in keybinds on evilem-map. There is no reliable mechanism for determining through what keymap a command was invoked, so there is no simple solution to this problem. Since these are meant to be "augmented" motion keys to begin with, this seemed like an acceptable compromise.
On an unrelated note, you should use :leader
instead of :map doom-leader-map
. They are equivalent.
I'll assume the issue was sufficiently resolved, but mark it as wontfix
since the underlying issue cannot be addressed. Thanks for bringing it to my attention!
As of 27cabea, you can bind +evil/easymotion
anywhere you like. I've found a way to work around the previously mentioned technical limitations.
Describe the issue Trying to map
SPC SPC
to+evil/easymotion
fails with "non-prefix key SPC" error. Other functions map just fine.The failing code looks like this:
However, both of these work just fine:
This suggests that there's something about the internals of
+evil/easymotion
that doesn't like being mapped to a prefix key...which is weird because the defaultg s
mapping usesg
as a prefix, which has other keys as well.System information