Emacs vs. Vi: The Showdown
Why is vi(m) superior to Emacs? Many reasons, the two chief ones being:
- chicks. —>
Standard disclaimer: I have used both editors for significant amounts of time.
Modal editing is the single most powerful tool in an editor’s repertoire. Faithful Emacs users will, of course, complain and reference “beep mode.” Presumably the real complaint is that vi has a steep learning curve. When you open an editor, you should be able to type and see text, not be reprimanded by malicious beeping.
I’ll grant that vi has a learning curve. To be as productive as in a plain editor a la Word/notepad, it takes a day or so. To be as productive as in Emacs, it’ll take some practice. But you can’t tell me vi is any more difficult or cryptic than Emacs. Which looks easier?
- control-x control-c
My fingers hurt just trying to imagine holding control/meta for every text operation. Modes offer sheer power. Rather than just having operations available to you via holding the control/meta keys, which is incredibly awkward with almost any modern keyboard, you have your entire keyboard available. Every key works together to alter text as fast as you can think. It’s rather impossible to describe the magic you can work with a few keys, but I’ve been using vi for years and still learn every day.
Beyond saving your fingers from meta-hell what does vi offer, you wonder? Well, it’s a text editor, for one. Emacs is more like the OS from hell, all packaged into one convenient huge binary. If I were an Emacs user, I’d at least have its startup time to blame for posting infrequently. Vi edits text. Emacs claims to, but it also claims to read email, newsgroups, the internet, calendars, IRC, play Tetris… Emacs has plugins to do just about anything except suck up all your memory – that, my friend, it does by default. Vim has plugins to edit text. Hrm.. that sounds about right for a text editor. Not to mention instant loading and a tiny footprint, while packing in all that power.
I know Emacs users can’t leave this one to the books, though. “Vi is the devil, it won’t stop beeping.” Put half as much time into vi as you did into emacs, and you might begin to appreciate it. Hell, take the time to learn vi while emacs is loading. The subtle change of mindset will overtake you. As John Arundel said, “Watching a vi guru doing some heavy editing on a file, as her fingers fly over the keys and textual transformations sweep across the screen, one could believe that one is in the presence of supernatural powers.”
Tim O’Reilly uses vi, and sells twice as many vi books as emacs books.