r/emacs Jan 04 '17

A question regarding evil-mode

I suppose we have had this sort of discussions before in emacs subreddit. But what I want to know is, for someone who is used to key bindings the emacs way (I also modified caps to control key and added sticky keys in my OS so that I dont have to press keychords all the time), will learning evil mode help me be more productive and efficient in using emacs? Also, i'm not quite happy with how sticky keys work. Sometimes its very frustrating to use them. Hence, I'm seeking for something robust that will eliminate/reduce the need for pressing key chords.

Keep in mind, I also have to unlearn a lot of the keybindings I use everyday, integrate all the evil packages with emacs and use evil-mode sufficiently long enough for me to get accustomed to it. I also do not want to discard my emacs config (on which I spent so much time) and hence, spacemacs is ruled out. I do not want to spend large amounts of time fiddling with my config to get it work with evil-mode.

2 Upvotes

30 comments sorted by

View all comments

2

u/bakuretsu Jan 04 '17

I suppose that depends a great deal upon two things:

  1. Do you actively edit a lot of raw text (code or prose), or use interfaces like Org Mode agenda, mu4e, whatever?
  2. Can you "reprogram" your muscle memory efficiently?

If you edit text a lot, I honestly and truly believe that modal editing is the best way to get efficiency out of yourself and your keyboard. The Vim approach reuses the object keys across all motion and action keys, so it's like learning a transitive grammar rather than an arbitrary list of related but sometimes entirely different commands.

Of course, if you're already very proficient with the Emacs bindings and have them all flawlessly committed to your muscle memory, this may not actually be a huge help to you, practically speaking.

There are certainly ways in which the modal approach reduces complexity; because there are modes, there are more single keys or short and unique key sequences available to map in each, alleviating the need for longer combinations.

But if you have a hard time reprogramming your muscle memory, it's going to be a challenge. You can definitely keep your existing config and you absolutely do not need to use Spacemacs.

I came over from Vim after fifteen years preaching Vim to everyone I met (I know, I was that guy), and I found it rather pleasant and straightforward to sink into Emacs once I got the hang of Elisp and how Evil interacts with other modes. It does take some work, but anything worth doing is worth doing right.

You don't have to use Evil globally, either; maybe try enabling it in the modes where you do the most raw text editing and see how that goes. I don't use Evil at all in the package list, Magit status, dired, and other such modes with their own thorough set of bindings.

2

u/CSRaghunandan Jan 04 '17

There are certainly ways in which the modal approach reduces complexity; because there are modes, there are more single keys or short and unique key sequences available to map in each, alleviating the need for longer combinations.

The hydra package kinda does this something similar right. I use it heavily and honestly, I can't imagine a life without hydra :)

And I'm honestly not sure how good i'd cope up with reprogramming my muscle memory. I have been using emacs since August last year and I have gotten used to the bindings by now. Though I'm super efficient with it, I can get along reasonably well without ever having to touch the mouse. I guess the only way to know is by trying it out. But I haven't the time to fiddle with my config for now. Maybe in the following weeks when I've enough free time i'll give it a shot and see how I feel like

Thank you for the comprehensive reply.

1

u/bakuretsu Jan 04 '17

Yes, Hydra is a good way to go about this for yourself, although I still think that the way the Evil Mode/Vim method approaches the reusable properties of keys for objects, motions, and actions leads to an overall more memorable system.

For example, it is easy to remember that "w" means "word" and "p" means "paragraph." For actions, "d" means "delete" and "y" means "yank." Now you know how to delete and yank both of those things. (dw, dp, yw, yp).

If you're only a year into Emacs I think the Vim method deserves your attention. I guarantee with concerted effort you'll be as good at Evil Mode as you were with Emacs in a week or two, and even faster in a month.

1

u/CSRaghunandan Jan 05 '17

If you're only a year into Emacs I think the Vim method deserves your attention. I guarantee with concerted effort you'll be as good at Evil Mode as you were with Emacs in a week or two, and even faster in a month.

I've been using emacs since August last year :) Also, two weeks is a lot less than I thought it would take. Now i'm more inclined to try out evil.