Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to add and configure evil-easymotion for spacemacs #6540

Closed
casertap opened this issue Jul 10, 2016 · 11 comments
Closed

How to add and configure evil-easymotion for spacemacs #6540

casertap opened this issue Jul 10, 2016 · 11 comments

Comments

@casertap
Copy link

I do not understand the configuration file very well.
Can you guys explain how to install and assign a keybinding to evil-easymotion?

so far I added this to my .spacemacs

dotspacemacs-additional-packages
   '(
     evil-easymotion
     )
@d12frosted
Copy link
Contributor

Hey @casertap,

Adding evil-easymotion to dotspacemacs-additional-packages list just makes Spacemacs install that package, but configuration is left to you. Usually configurations go to dotspacemacs/user-init or dotspacemacs/user-config functions. Usually you want the second function unless it's clearly said in package readme that something must be set before package is loaded. So in general, when you want to install additional package you have to follow that package's readme file. Just skip the section when it says package-install package-name <ret> (or similar) as it's handled by adding package to dotspacemacs-additional-packages.

As per your situation, please refer to evil-easymotion usage section. I am not evil user, so don't know which is the best key binding for that, but don't bind anything to SPC as it is evil leader by default in Spacemacs.

And aside the general question of how to install and configure addition packages, I would like to point you to Vim motions with avy section in Spacemacs documentation. This is not the same as evil-easymotion, but has some similarities (at least at the first glance).

@casertap
Copy link
Author

Thanks @d12frosted
I was interested to know in which section should I put
(evilem-define (kbd "SPC w") 'evil-forward-word-begin) ?
Is this biding a good choice ? A lot of other binding are available on SPC w so maybe not.
I did not found the functionality to jump to a particular word with avy. Maybe I am using it wrong.

@casertap
Copy link
Author

Maybe I should define
(evilem-define (kbd "SPC e m") 'evil-motion-state-map)
but then SPC e m is undefined

(defun dotspacemacs/user-config ()
  (evilem-define (kbd "SPC e m") 'evil-motion-state-map)
...
  (setq eclim-eclipse-dirs "/Users/pierrecaserta/java-mars/Eclipse.app/Contents/Eclipse/"
        eclim-executable "/Users/pierrecaserta/java-mars/Eclipse.app/Contents/Eclipse//eclim")
 ...

@casertap
Copy link
Author

actually SPC-SPC-char is doing what I was looking for: #6528
thanks

@d12frosted
Copy link
Contributor

@casertap FYI, SPC-SPC-char was changed on develop 😸

@casertap
Copy link
Author

@d12frosted what do you mean? this is a new feature?

@d12frosted
Copy link
Contributor

No, I mean, it was remapped to SPC j j char

@casertap
Copy link
Author

ok I am going to switch to the develop branch because I want to get the good habit of using SPC j j char as soon as possible.

@casertap
Copy link
Author

just one more thing I switched to develop branch I hit SPC f t to open neotree and it says SPC f t is undefined
also I get

Warning (initialization): An error occurred while loading `/Users/pierrecaserta/.emacs.d/init.el':
File error: Cannot open load file, no such file or directory, f

with --debug-init I have

Debugger entered--Lisp error: (file-error "Cannot open load file" "no such file or directory" "f")
require(f)
...

I think I was too ambitious, master branch will be fine for me.

@d12frosted
Copy link
Contributor

@casertap for that error see #6523

@duianto
Copy link
Contributor

duianto commented Apr 15, 2021

An evil-easymotion layer has been added to Spacemacs:
vim][new layer] add evil-easymotion layer #13981

When the evil-easymotion layer has been added,
then the evil-easymotion key binding prefix is: gs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants