As someone who isn't
a native of Unix-land, I see the great divide: some people choose vi
as their text editor of choice and some choose emacs. My belief is
that which you choose largely depends on who taught you to use an
editor – you adopt their choice and make it your own.
I'm coming to the
editor war armed with the internet, but without a guide. How am I
supposed to choose between these two? I used each of them briefly and
did a little reading, and here's what I found and what I thought:
1) Several of the
keys in emacs correspond to keys in the shell, like CTRL-K killing to
the end of line. It'd be nice to have a leg up on learning keys for
the shell.
2) The biggest thing
I saw people complain about when saying why they use vim is startup
time. I feel that this isn't as much of an issue as it used to be:
“slow” starting emacs starts in less than a second in my VM.
Maybe this was a big issue 25 years ago, but not so much now. It'll
be even less of an issue in another 10 years.
3) The second
biggest thing I saw when people said why they used vim was that emacs
had “stuff they didn't need.” For me, this falls pretty directly
into “things I don't care about.”
4) You can extend
emacs with an emacs-flavored Lisp. I wanted to take another look at
Lisp anyway.
5) Vi
has modes: either you're changing text or you're not. I'm not used to
it, and don't care for it.
OK, so it's clear
that I'm going to...wait, what? We're not done? OK.
6) The biggest
problem people should have
with emacs is the control and alt keys, which are used for
everything, so much so that they got sick of typing “Ctrl” and
just went with “C”. Save the file? C-x C-s. Exit? C-x C-c.
7)
Vi can be extended in different languages, but it looks like you have
to recompile it and link them together. I'm not sure how this works
yet.
8)
It looks like people generally agree that making changes to files is
generally quicker in vi.
9)
Vi uses Esc to get out of edit mode, which I don't like.
It looks like it has Ctrl-] as an alternate key for that.
10)
I don't really care about most of the things that I know are built is
an extras to emacs, like a news reader. Yeah, in the 80's I would
have liked that. Now not so much.
Looking
over my list, it seems like emacs is pretty much still the clear winner.
Except for one thing: the darn keyboards. All the keyboards I've used
have a shift on the right and a shift on the left. Capital A?
Right shift. Capital U? Left shift. And all the keyboards I've worked
with have the right shift in the same place, or at least close enough
that I can use it without thinking too hard.
The
Ctrl key is different, though. On
some keyboards, the right Ctrl key is here. On others, it's over
there. On others, it's gone completely. That means that in order to
use emacs effectively when switching computers, I'm going to have to
learn to use the left Ctrl key. Ugh. Left
Ctrl-x Ctrl-c? Yeah, I'm
afraid that's not going to work for me. I'm going to go with vim.
--
Update: I've waffled and am going with emacs. I'm going to make my Caps Lock key an extra Ctrl and see how that goes.
--
Update: I've waffled and am going with emacs. I'm going to make my Caps Lock key an extra Ctrl and see how that goes.
No comments:
Post a Comment