
Why I switched from Vim to Emacs - wtbob
https://matthaffner.wordpress.com/2016/12/07/why-i-switched-from-vim-to-emacs/
======
pmoriarty
_" If you wanted to modify this in a traditional terminal emulator, you would
probably use the up arrow to retrieve the last command, use the left arrow (or
Ctrl-Home) to get to the beginning of line to modify ‘rn’, then use the right
arrow (perhaps in combination with Ctrl) to modify the second instance of
folder 1."_

Not so. You can just type "set -o vi" in your shell, and do pretty much what
the OP does in emacs. So wanting to do this kind of editing in the shell is
not really a very good reason to switch to emacs. There are much better
reasons for doing that.

~~~
gkya
Except the shell session is a buffer in emacs and you can do anything in it.

~~~
spraak
Just hit Esc then V and it drops you into a vi/m buffer, too

~~~
gkya
Though if I'm not wrong you only get to edit current command line. The emacs
shell buffer allows random editing, i.e. you can run regex search/replace on
the output of a couple commands ago, then run it again through grep, or clean
up your shell buffer and save it to a file.

------
mi100hael
_> The Vim/Emacs debate is often heated, but from what I can tell, Emacs users
are more passionate. There are a number of Emacs meetups around the country
where users share their setup and demonstrate useful tricks._

That's just because Vim users are actually getting work done rather than going
to help sessions for their configuration.

~~~
NTripleOne
Really, because as far as I see it Vim users are sat on HN making snarky
little comments like yours. :~)

------
VT_Drew
I will give Emacs a try once I figure out how to exit Vim.

~~~
kazinator
Most interactive programs will succumb to this exit recipe:

    
    
      Ctrl-Z
      kill %1
    

Suspend to shell, kill job. Anything that won't suspend with Ctrl-Z should not
be used.

(Developers who flout important conventions of this sort should be punished
with disuse of their projects.)

~~~
lgas
There are GUI versions of emacs too, some on platforms where they are not
expected to respond to Ctrl-Z.

~~~
jjnoakes
Those have little 'x' buttons in the upper corner though.

------
pklausler
I finally wrote my own editor so that I'd have something that works exactly
the way that I want an editor to work. I don't need a built-in e-mail reader
or ELIZA clone or scripting language, just really good interaction with UNIX
text processing commands.

~~~
marssaxman
I ultimately did the same. I doubt anyone else will ever use it, but it was
fun to create and it suits me (almost) perfectly. There's something
comfortable about knowing every detail of the environment I spend most of my
day using; it has every feature I use regularly and none of the ones I don't.

Interesting that you are also a Dvorak user. I originally learned to type on a
Dvorak keyboard, and have only ever been able to hunt-and-peck on QWERTY. I
imagine that vim's interface might seem like less of an incomprehensible,
memory-dependent maze if one's fingers were accustomed to QWERTY. I tried to
learn it once, with a little cheat sheet taped to my monitor, but I've never
been any good at rote memorization, so I didn't really get anywhere with it
and went back to nano.

~~~
0x38B
I switched to Colemak last year, and decided not to do any remapping. After a
few weeks, I had no problems using Vim with the new layout. It helps that
Colemak doesn't completely rearrange the keyboard.

Now my problem is that using Vim with any layout other than Colemak (read:
QWERTY) is awkward.

------
falcolas
I tried the conversion to Emacs using Spacemacs, but it repeatedly froze up on
me, something deep inside locked in a tight loop, turning my laptop into a
space heater. No custom plugins, using only a smattering of Spacemacs provided
modes.

I went back and tried it again some two major versions later, with the same
problem. I eventually narrowed it down to the Go major mode, but I didn't have
the perseverance to continue. Not when the same Go integrations were working
just fine in Vim.

Oh, yeah, and it still bugs me that Evil mode treats C-] word boundaries
differently than Emacs M-. (which actually matches how Vim's word boundaries
work by default).

~~~
qwertyuiop924
>it still bugs me that Evil mode treats C-] word boundaries differently than
Emacs M-.

This is Emacs, not vi: If you don't like something, you can just change it.

~~~
falcolas
This is my professional career. After two hours of digging into both emacs and
evil to try and find the appropriate word boundary combination I realized I
had better things to do with my time than fix a broken editor.

~~~
kahrkunne
"I don't like the default setting of this one specific command because it's
subtly different from what I'm used to" isn't the same as "broken editor"

~~~
falcolas
It was breaking the word barrier on underscores, which effectively made it
useless (to me, needless to say) for writing Python code, since I use tags for
navigating code regularly.

That's more than "subtly different".

~~~
qwertyuiop924
BTW, [http://emacs.stackexchange.com/questions/9583/how-to-
treat-u...](http://emacs.stackexchange.com/questions/9583/how-to-treat-
underscore-as-part-of-the-word) may be able to help.

------
mxvzr
I see no mention of the emacs daemon [1] which I've found very useful in
resource constrained environments (ie. tiny VMs or underpowered chromebooks).
That's especially true if you bring out the big guns like Spacemacs.

[1]
[https://wiki.archlinux.org/index.php/Emacs#As_a_daemon](https://wiki.archlinux.org/index.php/Emacs#As_a_daemon)

~~~
pawadu
Is emacs really that resource hungry? I started using emacs for writing C code
on a machine with 1MB of memory.

I feel that these complaints come mostly from people that have installed a
ridiculous number of very inefficient plugins to make emacs look like
something else. Spaceemacs in particular is big & slow (and IMO ugly on most
devices).

~~~
mxvzr
No you're right it's not resource hungry: if you have an empty (or sane)
~/.emacs and ~/.emacs.d then it is completly fine. However if you have the
habit of opening a new instance from the command line for a given file rather
that go back to your already openned emacs instance, like I do, it will add up
rather quickly (and the buffers won't be shared accross these multiple
instances).

With spacemacs it becomes particularly problematic (especially in regards to
start up times), and I think that's where the emacs daemon truly shines.

(edit: also no complaints here; I just feel this daemon is great and wanted to
share the sentiment; it also felt relevant as AFAIK vim has no such feature)

------
melling
He still uses vim bindings. Emacs is an editor construction kit. It can become
vim, or another editor.

What we really need is a 21st century editor construction kit with Minority
Report gestures, eye tracking, and voice input, as well as the keyboard.

~~~
pmoriarty
Here's voice input for emacs: [1], [2]

And for vim (inspired by [2]): [3]

I'm sure gesture tracking would probably not be too hard, using any of a
number of VR input devices now on the market. Eye tracking would be harder, as
I'm not aware of any consumer-level eye-tracking technologies out there. You
could certainly have head-tracking pretty easily, though.

Now integrating this in a way that would actually be fluid, natural, and
useful is another story, though. Also, I'm personally not sure how many big
body movements I want to be doing while using my computer (unless I'm trying
to exercise, play a game, draw, conduct music, or lose weight).

Ideally, I'd want to be as motionless as possible while being as comfortable
as possible and while having maximum flexibility and efficiency of input.
Keyboards are pretty good for that.

[1] -
[https://www.youtube.com/watch?v=77zPOyMmMPQ](https://www.youtube.com/watch?v=77zPOyMmMPQ)

[2] -
[https://www.youtube.com/watch?v=8SkdfdXWYaI](https://www.youtube.com/watch?v=8SkdfdXWYaI)

[3] -
[https://www.youtube.com/watch?v=TEBMlXRjhZY](https://www.youtube.com/watch?v=TEBMlXRjhZY)

~~~
melling
[2] is Thomas Ballinger - Terminal whispering - PyCon 2015. Is that right?

VoiceCode is a $300 product. [http://voicecode.io](http://voicecode.io)

Is it worth the money?

~~~
pmoriarty
Sorry. That was the wrong video. Fixed.

------
huac
I'm considering picking up Spacemacs just for org-mode. Is there anything for
vim that can match those kinds of capabilities?

~~~
dude01
I'm a vim-guy. I've been using vimoutliner
([https://github.com/vimoutliner/vimoutliner](https://github.com/vimoutliner/vimoutliner))
for my todo lists, since I put my notes inside my todo lists. With
vimoutliner, you can make any line have a checkbox [_], and it understands
that a top-level is done only if all of its children are done.

~~~
sujay_m
Its true that org mode is useful for organising various stuff, but it can also
do other things, literate programming. it also lets you work with multiple
programming languages at the same time. I think that is more powerful than
even the jupyter notebooks. [http://orgmode.org/worg/org-
contrib/babel/intro.html](http://orgmode.org/worg/org-
contrib/babel/intro.html)

~~~
akkartik
Yes, super jealous of org mode. For my literate programming I try to follow
the Vim philosophy of delegating to external tools:
[http://akkartik.name/post/wart-layers](http://akkartik.name/post/wart-
layers). My approach adds some new capabilities, but it's not nearly as nice
an _experience_.

------
kazinator
Funny, I'm a huge Lisper, yet I don't use Emacs. Conversely, I met people who
would live and die by Emacs, who didn't know any Lisp, Emacs or otherwise.

I'm worried that if I started using Emacs, I'd start hacking the Elisp (which
I'd be terribly good at), and hate the lack of lexical scope, etc.

I had some nice exchanges with Stefan; we discussed the implementation of
generalized places not long ago:

[https://groups.google.com/forum/#!msg/comp.lang.lisp/5By5NL4...](https://groups.google.com/forum/#!msg/comp.lang.lisp/5By5NL4cXWk/xis1dsgKAQAJ)

In TXR Lisp I implemented places in quite a different way from CL SETF
expanders; from Stefan's comments I was informed that Emacs' "gv.el" is doing
it in a similar way to my approach.

~~~
wtbob
> I'm worried that if I started using Emacs, I'd start hacking the Elisp
> (which I'd be terribly good at), and hate the lack of lexical scope, etc.

emacs has lexical scope these days:-)

[https://www.emacswiki.org/emacs/LexicalBinding](https://www.emacswiki.org/emacs/LexicalBinding)

elisp still isn't nearly as good as Common Lisp, but it at least has lexical
scope now.

------
qwertyuiop924
To this day, I'm pretty sure Emacs is the best development environment for
dynamic languages (save maybe the LispM or the Smalltalk IDE, but that's
another story), because it really embraces the REPL, something that seems to
be against the trend with most IDEs.

------
mikestew
Just a matter of what you want your tool to do, and how much you're willing to
put up with. Do you really want a _meetup_ for your editor? Are you willing to
change operating systems just to make it easier to install your editor? Versus
the "nightmare" of having to download something? (I can't tell if the author
is being sarcastic or not in complaining about something that could be
scripted.) Do you want to edit text, or play Tetris? Do you want to live
inside your editor, or is it just one piece in a larger puzzle? Do you like to
endlessly fiddle with your configuration, or get work done?

I'm not saying either one is right. To me, it's kind of like Android vs.
iPhone. Some are annoyed that they can't change the font weight on the
wireless settings screen on iPhone. Some just want to connect to the network.
Some want a Swiss army knife, some just want a sharp blade. The same argument
has gone on for thirty years, but we collectively pretend we've brought
something new to the table every time the subject comes up.

~~~
fulafel
Which OS is Emacs difficult to install on, in your opinion?

~~~
mikestew
SCO Unix System V, the last operating on which I've run Emacs. Huge pain in
the arse.

Or Ubuntu, according to the author of the post.

~~~
throwanem
I don't think he was saying that Emacs is hard to install on Ubuntu. (It's
not.) OP said earlier in the post that he switched to Arch because Ubuntu
doesn't package a version of Emacs new enough to satisfy the requirements on
the latest version of Spacemacs, which wants Emacs 24.4, which in turn is only
available from the repo if you're running Ubuntu 16.x. Building Emacs 24.4
from source seems to me like it would be easier than switching distros, but
apparently OP feels differently, and more power to him.

The comparison between Arch and Ubuntu appeared rather to be on the basis of
FSF blessedness:

> (the FSF probably wouldn’t like that I’m using Arch Linux, but it’s
> certainly better than Ubuntu)

which would make sense, considering that Ubuntu gets quite a lot more stick
than Arch on the relevant FSF page: [https://www.gnu.org/distros/common-
distros.en.html](https://www.gnu.org/distros/common-distros.en.html)

~~~
pawadu
> wants Emacs 24.4, which in turn is only available from the repo if you're
> running Ubuntu 16.x.

This is not an emacs problem, it is much bigger than that. Ubuntu, and Debian
(unless you are on unstable) ship with ancient versions of many things. This
shows how inefficient the package maintainer system is. Lets see if snappy (or
some competing technology) manages to fix that.

~~~
disgruntledphd2
I find it odd that people seem unaware of build-dep, and downloading the
source.

I'm not a developer (I do data analysis), but compiling Emacs from source on
Ubuntu (after running build-dep emacs24) has never caused me problems.

But hey, I'm sure Arch is awesome, and if I had more time I'd totally be
running it.

------
pmoriarty
I've used vim (vi and some other vi colones before that) for over 25 years,
and switched mostly to emacs (with evil) about 6 years ago or so.

One of the main reasons I switched was because I fell in love with Scheme (and
Lisp before that), and loved the idea of an editor that was fully integrated
with Lisp, was scripted in Lisp, was mostly even written in Lisp, and had
powerful Lisp-editing modes like Slime. It is possible to script vim through
Scheme, but 99% of vim's scripts are written in vimscript, and that's really
what the vim ecosystem is designed around. So emacs was a clear winner here.

I also liked the idea of having email, web browsing, RSS news reading, IRC,
Usenet, the shell, and more fully integrated in to the editor. Ideally, every
app would be integrated in to my editor, and I'd love to command them all from
within there. This is more or less what emacs promised.

org-mode was another big draw. It seemed cool, and I wanted to find out if it
was really as big a deal as everyone said. It is. All my note-taking is now in
org, and I intend to move my browser bookmarks to it too. I've since tried
various org-mode clones in vim, and they're not nearly as good.

Finally, what really won me over was evil-mode, which allowed me to keep my
decades of vim muscle memory and preference for modal editing.

I spent several months, spending 10 hours a day to customize emacs the way I
liked it, and to bring it mostly up to parity with my vim config (which was
thousands and thousands of lines long), along with customizing some emacs
extensions that had no vim equivalent (like emacs-w3m, which is an embedded
web browser, which is still super handy despite not working with javascript).
It took that long despite me knowing Common Lisp and Scheme before switching
to emacs, which made learning Elisp a breeze compared to the extra effort it
would take someone coming from vim who didn't know any Lisp.

And still, even after all that work, I haven't gotten around to learning and
customizing many of the things I really want to use emacs for, like email,
IRC, RSS, Slime, and the various other extensions made for editing Lisp and
Scheme.

So I found the switch to be a ton of work, which was worth it for me, since
I'm still using emacs instead of vim, and don't intend to switch back. But
others who are considering a switch from vim to emacs should also be prepared
to do a lot of work customizing emacs to your liking. It's a never-ending
process, really, just as it is with vim.

Even though I've switched to emacs as my primary editor, I still use both.
Each have their strengths and weaknesses, and I still love vim (which comes in
handy in certain situations where emacs just isn't cutting it for me).

------
nonsince
I discovered spacemacs literally days ago, and had this exact experience
almost word-for-word. Interesting that this article should appear now. Loving
spacemacs so far, I actually prefer its keybindings to vim's, even though the
space-prefixed style was what kept me away from it when I first discovered it.

------
staked
Even though I've been happy with Vi/Vim for 15+ years I've always been
intrigued by all of the "extras" Emacs can do.

Any recommendations on guides integrating email/IRC/RSS into an Emacs
workflow?

~~~
mordocai
GNUs is notoriously hard to figure out how to config (though once I got it
configured I've never had to mess it up again) but is the primary email client
for people who want to directly grab their email in emacs instead of using a
third party email sync and then reading it in emacs.

ERC is built in, pretty good for IRC, very easy to use, and very configurable.
There are other IRC clients as well.

There are RSS readers in emacs as well but I don't currently use them. I think
elfeed is the cool one to use nowadays.

------
Dowwie
I thought political posts were off limits this week?

~~~
dindresto
Yes, but religious posts are not. :P

~~~
sctb
Taking this back into serious territory for a moment, there's an update on no-
politics-for-a-week:
[https://news.ycombinator.com/item?id=13131251](https://news.ycombinator.com/item?id=13131251).

------
adictator
Being a long time Vim user, and having dabbled in Emacs just a teeny weeny
bit, I'm convinced that "Emacs is a wonderful operating system, lacking only a
decent editor"!

~~~
curried_haskell
That's why you can use vim in emacs. Since I've been using spacemacs, I don't
miss vim anymore. Use the best editor together with the best operating system!

------
sshrinivasan
Its almost 2017. Nobody cares.

~~~
mmartinson
Why comment at all if you're going to be merely dismissive and
nonconstructive?

