Live data from Hacker News

Where Vim Came From

twobithistory.org

151–160 of 265 posts

Re: Where Vim Came From

#151
post #38

> While Emacs certainly still has a following, some people think that the Editor Wars are over and that Vim won.16 The 2018 Stack Overflow Developer Survey suggests that this is true; only 4.1% of respondents used Emacs. I'm an Emacs user for years now and love the editor. But I'm curious about this claim of its poor popularity. The article refers to a piece from http://www.linux-magazine.com/Online/Blogs/Off-the-Bea…

Very difficult to do with free software and completely irrelevant really. At some point in your life it's OK to accept that you're the weird one. We're the weird ones. Donald Knuth, Richard Stallman, Guido van Rossum, Rich Hickey et al are the weird ones. I don't know why emacs is such a barrier to everyone else or why vim is so attractive. But I don't understand most other humans about most things.

I have used emacs for the past ~12 years, before that I used vim for a couple of years. IMHO, both editors have their strong points.

Vi has the advantage that you can learn the basics in an hour or so, and from there on out it's mostly about training your muscle memory. You do a lot of stuff with very few keystrokes.

Emacs, of course, is mostly about extending and customizing. Therefore, emacs requires a larger up-front investment of time, before you get to the point where that pays off. Once it does, it is awesome, but I can understand that people tend to choose an editor that lets them be productive faster.

There might be more to it - I never did much customizing when using any variant of vi, for example. But that was my experience when using vi and later emacs.

Re: Where Vim Came From

#152

Earlier quoted context omitted.

The vim commands are mostly great, they are a fantastic set of hyper-productive defaults we all should learn. One of the reasons is that almost every other editor has the ability to use vim commands. Evil, the Emacs vim plugin, implements the vim commands plus some popular vim plugins (like vim-surround), and the resulting experience is awesome. I'm a heavy Spacemacs user and the user experience is so well done that…

> One of the reasons is that almost every other editor has the ability to use vim commands. Really? It would have to be a modal editor to use vim commands. Emacs commands, on the other hand, could work with the vast majority of editors out there, and actually do work in many cases. readline, for example, which is used by bash and many other CLI programs uses emacs bindings. fish and zsh use them too.

> It would have to be a modal editor to use vim commands.

Or it would have to emulate them. Which is what VSCode, Atom, Visual Studio, Eclipse, Intellij, Netbeans, Kate all do. Those are just the ones I have used, I'm sure there are plenty of others.

Re: Where Vim Came From

#153

Earlier quoted context omitted.

Very difficult to do with free software and completely irrelevant really. At some point in your life it's OK to accept that you're the weird one. We're the weird ones. Donald Knuth, Richard Stallman, Guido van Rossum, Rich Hickey et al are the weird ones. I don't know why emacs is such a barrier to everyone else or why vim is so attractive. But I don't understand most other humans about most things.

Ok let me be very honest here, let's look at both editors learning curves - vi/vim You need to learn to open a file, edit it, move around and exit and the edit/view mode. Everybody learns how to do it. At first it sucks but you can learn this in 5 min. Nothing too hard, and yes, do use the direction keys, it's not the 70s anymore. From there you can learn other things - Emacs You try reading anything about it, there'…

> use the direction keys, it's not the 70s anymore.

In my experience, the fact that I can navigate a file without taking my hands off the home row far outweighs any disadvantages hjkl might have.

With emacs, the big point is that you can do so many things in it that you never have to leave it; that also means once you have the keyboard shortcuts memorized, you can use them everywhere - besides editing text, emacs can serve as a mail client, a web browser, an IRC client, a music player, telnet/ssh client / terminal emulator (kind of), you can even play Nethack in emacs.

You can't expect to become fluent in emacs within a couple of minutes, but if you are willing to stick around, the time spent learning emacs pays off big time.

Re: Where Vim Came From

#154

Earlier quoted context omitted.

The vim commands are mostly great, they are a fantastic set of hyper-productive defaults we all should learn. One of the reasons is that almost every other editor has the ability to use vim commands. Evil, the Emacs vim plugin, implements the vim commands plus some popular vim plugins (like vim-surround), and the resulting experience is awesome. I'm a heavy Spacemacs user and the user experience is so well done that…

> One of the reasons is that almost every other editor has the ability to use vim commands. Really? It would have to be a modal editor to use vim commands. Emacs commands, on the other hand, could work with the vast majority of editors out there, and actually do work in many cases. readline, for example, which is used by bash and many other CLI programs uses emacs bindings. fish and zsh use them too.

On macOS, the standard widget for text input supports emacs-style shortcuts, too, which means you can use them pretty much everywhere. One of the few things I miss about macOS.

Re: Where Vim Came From

#155
post #35

Earlier quoted context omitted.

I'm always kind of curious about comments like this -- it seems everybody knows you have to play games of Twister and hit twelve control keys simultaneously to do even the most basic things in Emacs. But... I use Emacs. I've been using it for almost twenty years. And I'm struggling to think of anything I use regularly the involves hitting more than two total keys simultaneously (keys pressed in sequence obviously don…

> Do people genuinely run into cases where they frequently have to be hitting 3+ keys simultaneously to use Emacs? Paredit mode has several useful ones for writing elisp. - C-M-f, C-M-b, and C-M-u (forward-sexp, back-sexp, and up-sexp) - C-( and C-) (barf and slurp commands) - C-M-k (kill-sexp) M-: (eval-expression in the minibuffer) is also a frequent command for me. I've overlaid several keys in the number row with…

Only barf and slurp are paredit commands, the others you mentioned (the sexp motion and killing commands) are stock Emacs!

(Well, by default C-M-u is bound to backward-up-list, either that's what you meant or paredit really defines a slightly different up-sexp commands. I don't remember right now.)

The worst command I regularly use, in terms of number of modifiers, is definitely C-M-% for query-replace-regexp.

Re: Where Vim Came From

#156
post #112
post #79

Earlier quoted context omitted.

Vim is attractive to many because it launches in a fraction of a second. This is especially important to sysadmins, who don't "live in a text editor." It's also quite popular to use vim without customization. I understand that some people have simple needs. I don't. The editor wars are over for me and Emacs has won.

Not just its launch time but its ubiquity, vi comes installed on pretty much every linux/unix machine no matter how minimal the install so if you are a sysadmin whose job involves jumping between machines a lot it makes far more sense to learn vi then install emacs everywhere. Its also the reason to use it without customization so you dont come to rely on a feature that isn't installed on that one machine with a crit…

OTOH, emacs has TRAMP which allows you to edit files remotely, using ftp or ssh as the transport layer. (Okay, I do not use that feature often, and I do still use vi sometimes for quickly editing a config file or something).

Re: Where Vim Came From

#157
post #38

> While Emacs certainly still has a following, some people think that the Editor Wars are over and that Vim won.16 The 2018 Stack Overflow Developer Survey suggests that this is true; only 4.1% of respondents used Emacs. I'm an Emacs user for years now and love the editor. But I'm curious about this claim of its poor popularity. The article refers to a piece from http://www.linux-magazine.com/Online/Blogs/Off-the-Bea…

What about starting a new poll? :) https://docs.google.com/forms/d/e/1FAIpQLSfgn71T6I3olMRNCTDQ... Feel free to suggest options adds or edits

There are already 195 answers :) you can see the results file here: https://docs.google.com/spreadsheets/d/1feDCU-yvdbhRCgMqren2...

Re: Where Vim Came From

#158
post #79

Earlier quoted context omitted.

Vim is attractive to many because it launches in a fraction of a second. This is especially important to sysadmins, who don't "live in a text editor." It's also quite popular to use vim without customization. I understand that some people have simple needs. I don't. The editor wars are over for me and Emacs has won.

Startup time is a non-issue for both Vim and GNU Emacs on modern hardware. (It was not ever so: I remember first meeting Emacs under DOS on a 20MHz 386. It was not speedy.) Perhaps another underrated issue affecting relative uptake is keyboard layout. As the OP explained, Berkeley vi was originally developed on an ADM-3A tty, with no arrow keys and the "Esc" key where a modern keyboard would position the "Tab" key. I…

> every time I've tried to spend serious time in Emacs over the past 30 years on a PC or Mac keyboard, I've ended up with stabbing pains in my wrists within a week

I used to think "emacs pinky" was a joke, but it is real. Eventually I learned how to re-map Caps Lock to be a Ctrl-key (I never used Caps Lock anyway), and Caps Lock is far more comfortable to reach with my pinky than either of the regular Ctrl-keys.

Re: Where Vim Came From

#159
post #134

Earlier quoted context omitted.

Have you tried exiting vim? :D

I know this was intended as a joke, but exiting vim is now much easier than exiting emacs (IMO), assuming that the user has some experience with UNIX and uses `Ctrl+C` to exit most programs. If I start vim and press `Ctrl+C` I get an helpful message saying "Type :qa and press to abandon all changes and exit Vim". If I do the same on emacs, first the help screen disappears (which was the one telling me to use `C-x C-c…

vim is a text-mode program. Emacs is not. Exiting is easy for anyone, just click the x in the window and poof! It's gone.

Re: Where Vim Came From

#160

Earlier quoted context omitted.

Very difficult to do with free software and completely irrelevant really. At some point in your life it's OK to accept that you're the weird one. We're the weird ones. Donald Knuth, Richard Stallman, Guido van Rossum, Rich Hickey et al are the weird ones. I don't know why emacs is such a barrier to everyone else or why vim is so attractive. But I don't understand most other humans about most things.

Ok let me be very honest here, let's look at both editors learning curves - vi/vim You need to learn to open a file, edit it, move around and exit and the edit/view mode. Everybody learns how to do it. At first it sucks but you can learn this in 5 min. Nothing too hard, and yes, do use the direction keys, it's not the 70s anymore. From there you can learn other things - Emacs You try reading anything about it, there'…

> Nothing too hard, and yes, do use the direction keys, it's not the 70s anymore.

Yet another thing 70s got better than today's software. The defaults you're used to are a historical accident, and are also crap - that is, an impediment to productivity.

> I tried opening the help of both programs (...)

> Emacs? I'll copy-paste here (key bindings help)

How on Earth did you get there? The very first thing in the Help menu (also conveniently bound under C-h t, and also conveniently listed in help-for-help view that shows if you press C-h C-h) is the Emacs Tutorial. The thing that's designed to teach you the basics quickly. Just read and follow the instructions, and it will all make sense.

As for whatever you just pasted here (looks a bit like output of C-x ?), it's probably part of the self-documenting aspect of Emacs, which you're yet to discover. That is, you can get help and documentation on absolutely everything - including runtime values of key bindings, variables and functions (both C and elisp) used by Emacs.

> Everything seems like it's actively fighting the user, and making it more difficult or convoluted than it should.

It's not. It's just:

- following a (somewhat) consistent set of UX principles that are older than IBM CUA (which gave you CTRL+C / CTRL+V, etc.). Older does not mean worse.

- a tool for serious users, who are not afraid of spending 5-15 minutes reading the tutorial.

To be clear, I'm not arguing here for Emacs over Vim. I'm arguing here against the stupid - and stupidly common - approach that proper UX means a newcomer must be able to use the software productively after 30 seconds of exposure to it. It's a stupid approach, because the only way to do this is to dumb down the program to the point it does so little that it can be mastered in 30 seconds. Emacs, like Vim, and Blender, are tools for people who want to be productive. A prerequisite here is the willingness to learn something.

Post reply on HN