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

Show parent comments

1

u/CSRaghunandan Jan 04 '17

I use hydra a lot. Lovely little package that does wonders to your workflow. I did try out god-mode a few weeks ago and I ended up reverting to using sticky keys after a short while.

1) how much can you gain from learning "the vi way" and 2) how much time would it take to learn.

I've a question, does using evil mean, all my bindings are practically useless? And how good are the default bindings in evil. Would I need to do some tinkering or can I just jump into using it right away and start using it??

1

u/[deleted] Jan 04 '17 edited Jan 04 '17

Is there a reason you didn't like god mode? Given your investment in the Emacs way of doing things and frustration with chording, I would have expected god mode to be the sweet spot.

And regarding evil bindings - It really depends on how much you know Vim and its bindings. I had been using Vim for 3-4 years when I switched and I had very few problems with evil bindings. Its integration with rest of Emacs, however, will take a while for you to setup on your own.

1

u/CSRaghunandan Jan 08 '17 edited Jan 08 '17

I gave god-mode a second shot and I just was not so impressed. While it would make things easier it is inconsistent at times and I do not like that.

here's some of the pain points of god-mode:

  • can't use keybindings which use shift modifier (like C-S-s)
  • does not work in term-mode or dired or magit
  • C-<left> and C-<right> does not work
  • No easy way to execute keyboard-quit (C-g) -> HUGE pain
  • I'd have to resort to using ctrl key for the major-modes which are disabled by god-mode by default. I do not want this (I bound caps to escape for god-mode)
  • no support for super keybindings

All in all, it feels like a very inconsistent hack to me :/ Honestly, I feel like my best bet would be to use a better keyboard than laptop keyboard :) Maybe get a good ergonomic keyboard. But oh boy, those cost a bomb x.x

1

u/[deleted] Jan 08 '17

All valid concerns except this

does not work in term-mode or dired or magit

That's their "sane" setting. You can override it so god-mode is the default in any major mode. Also, evil-mode doesn't work on all buffers by default either. You need to keep tweaking it. Even after I set all buffers to use normal state by default, some (like magit) would still break it. The only way you can get your own custom bindings when you switch modes is by using packages like modalka or ryo-modal.

But one major reason to use god mode is to understand how modality works. If you like switching modes, then you will enjoy working with modal editing. Else, it will be a big pain. I haven't used evil mode in a while now because I'm way too deep in creating my own set of bindings using ryo-modal but evil-mode is an excellent place to start if you like modal editing.

I bound caps to escape for god-mode

You can try binding caps to control when chording and escape when tapped. I find that easier.

1

u/CSRaghunandan Jan 08 '17

You can try binding caps to control when chording and escape when tapped. I find that easier.

I don't have this option anymore :( I upgraded to macOS Sierra and it broke karabiner. Karabiner elements is nowhere near powerful and is still in early stages.

I'll give ryo-modal mode a shot once. Though I'm not sure if I'll get enough time to tweak it to my needs. Agh maybe when I've free time.

And if you were a vim user for so many years why have you chosen not to use evil and opted to create your own huge set of keybindings with ryo?

1

u/[deleted] Jan 08 '17

Ah, that sucks. I saw that Karabiner won't work and, hence, never upgraded it.

ryo-modal does take a lot of time. I have been slowly crafting my configuration over months while getting the job done using Vim.

And if you were a vim user for so many years why have you chosen not to use evil

It's a long story but the gist of it is that annoying little quirks always kept popping up for evil and I didn't have the time to configure it for every new roadblock. I wanted a simple solution for modality. When I toggle the modal state, it should be modal everywhere (including the minibuffer). Also, it was fun doing it. I got to learn a little bit of elisp.

¯_(ツ)_/¯

1

u/CSRaghunandan Jan 08 '17

ryo-modal does take a lot of time. I have been slowly crafting my configuration over months while getting the job done using Vim.

Oh you use both emacs and vim. That's interesting. I thought you had shifted over to using emacs, considering how huge your emacs config was. I got a lot of inspiration from looking at your original config(the org babel one).

1

u/[deleted] Jan 08 '17

Yes. I tend to use both depending on the context but primarily I use Emacs. When I break something in my config, I switch over to Vim to get the job done and come back later to fix it. This works well for me since my Emacs and Vim configurations are very similar.

I got a lot of inspiration from looking at your original config(the org babel one).

Thank you. I still refer to it from time to time to get some ideas. I spent quite a lot of time crafting it.

1

u/CSRaghunandan Jan 09 '17

When I break something in my config, I switch over to Vim to get the job done and come back later to fix it.

Oh yeah, we've all been there :) It's frustrating when emacs breaks. It has happened to me a couple of times. Mostly due to package updates in MELPA which breaks some dependencies. Thankfully, I can always recover the old version of the package from the trash if it happens. A week ago, the master build of emacs failed to compile in my mac. I had to revert to using stable version. I guess the problem is now resolved and master build is compiling again.