News for hackers. Stuff that matters.
Re:Why, oh why, do those nutheads use vi? by drblast on Thursday February 02, 2012 @09:54AM (#3542871)
Don't ever start using vi. After you do, any text editor that you are forced to use that doesn't have vi key bindings will give you fits and make you cry.

Learning vi is your standard process of enlightenment and elation followed by a lifetime of disappointment. Think about how you'd feel if you ate the best meal of your life at age 13, and the restaurant where you ate it went out of business the next day.

You'll be frustrated by all other software. You'll wander around trying to explain to other people why the thing you had was so good, and it was so easy, and that nothing else compares, and wouldn't it be great if everyone did things this way.

Exactly like the author of this article.

You have been warned.

Re:Why, oh why, do those nutheads use vi? by Florin_Andrei on Thursday February 02, 2012 @01:46PM (#3543933)
I learned the bare minimum required to use vi. Insert, find, override-save... That's pretty much it. When vi is the only option, it's good enough; otherwise I'm free to use different editors.
Re:Why, oh why, do those nutheads use vi? by Domenic_S on Thursday February 02, 2012 @02:07PM (#3544013)
Funny that you got downvoted. The entire industry has spent the last... forever years making things easier to use/gui-fied, and you get dinged for wanting to use those improvements.
Re:Why, oh why, do those nutheads use vi? by staunch on Thursday February 02, 2012 @03:11PM (#3544224)
Easier for a beginner ≠ better for an expert.
Re:Why, oh why, do those nutheads use vi? by tomkarlo on Thursday February 02, 2012 @08:21PM (#3545316)
The goal of a new text editor shouldn't be to make things better for people who are already experts on an existing platform. It should be to make it better for beginners on the new editor (because initially, everyone is) and better for them when they become experts.

Saying "I'm an expert at vi, and other editors don't work as well for me" is a pretty meaningless statement. Of course they don't. It's like saying "I speak English, and I find speaking Spanish really hard, so English must be the best."

Re:Why, oh why, do those nutheads use vi? by tikhonj on Thursday February 02, 2012 @09:25PM (#3545443)
But that's not what people are saying. What people are saying is that Vi is better for Vi experts than Blub editor is for Blub editor experts.
Re:Why, oh why, do those nutheads use vi? by tomkarlo on Sunday February 05, 2012 @02:36AM (#3553549)
Except it's always a Vi expert making that assertion. I've yet to hear anyone say, I'm a Blub expert, but Vi is better.
Re:Why, oh why, do those nutheads use vi? by genbattle on Thursday February 02, 2012 @10:14PM (#3545561)
I think this is a case of not being able to have your cake and eat it too; you can make something easier to use, but it usually comes as a compromise to more expert users because you have to simplify the interface, remove functionality, reduce configuration options, etc. Conversely, adding more power will usually mean increasing the difficulty for beginners; if you require that users are comfortable with using a semi-programming language to write configuration files, you get more options and more power than you could via a simple and straightforward gui.

In the end I don't think either approach is better, just different. To address your first statement, I think editors can either choose to become better for experts in a particular domain, or they can choose to be easier to learn for beginners, or some compromise between the two. I have yet to see an application that manages to do both.

I agree that someone's subjective opinion of editors other than the one(s) they use is not very useful, but i don't think that was the point of the post you replied to. He was simply stating what I stated above; an app that is good for a beginner is not necessarily the best for an expert, and in the end you have to find some compromise between the two.

EDIT: For the record, I think vim has a pretty good learning curve; vimtutor is great, and you only really need to know the most basic parts of modal switching for gvim to be used like any other text editor. Once you gain some mastery of things like movement command, macros, markers, etc. you can really start to accelerate your workflow. I'm not one of those people that started using hjkl from day one.

Re:Why, oh why, do those nutheads use vi? by Florin_Andrei on Thursday February 02, 2012 @04:19PM (#3544542)
I'm actually quite satisfied in being a perpetual "vi beginner". With regard to Linux however, I started using it (professionally too) before most people (including IT professionals) heard of it at all. I enjoy puzzling my coworkers by declaring that I am "vi-ignorant and proud of it". :)

Anyway, I guess I just dislike vi because it's different from everything else. I like things that are uniform. That's what really saves a lot of time and effort in the long run.

On servers, I only require a few simple things of the editor; for everything else, there's always the command line or one of the P* scripting languages. On my laptop, I can install anything I want. Never saw the point in wasting time to learn an arcane editor from the '70s.

Re:Why, oh why, do those nutheads use vi? by sofal on Thursday February 02, 2012 @06:38PM (#3545079)
Never saw the point in wasting time to learn an arcane editor from the '70s.

Well apparently you wasted your time learning an arcane command line interface from the 70s.

Re:Why, oh why, do those nutheads use vi? by staunch on Thursday February 02, 2012 @08:15PM (#3545308)
Linux is to Unix as Vim is to Vi. Based on 70s tech, developed in modern times.
Re:Why, oh why, do those nutheads use vi? by sukuriant on Thursday February 02, 2012 @03:17PM (#3544236)
Better for expert != harder for beginner
Re:Why, oh why, do those nutheads use vi? by staunch on Thursday February 02, 2012 @04:08PM (#3544484)
It's not impossible to make tools that are easy for amateurs and powerful for professionals, but empirically it's rare.

The reason is pretty simple. Take any tool, like Notepad, and start making it better for professional usage. Pretty soon it's full of features and shortcuts that help professionals and confuse amateurs.

It's as it should be though. It makes good sense for professionals to spend more time upfront learning more powerful tools because the savings over their career will be massive.

The amateur won't see any benefit from spending a lot of time learning if they only use the tool for a short period.

Re:Why, oh why, do those nutheads use vi? by metaobject on Thursday February 02, 2012 @11:16AM (#3543258)
Don't ever start using emacs. After you do, any text editor that you are forced to use that doesn't have emacs key bindings will give you fits and make you cry.

Learning emacs is your standard process of enlightenment and elation followed by a lifetime of disappointment. Think about how you'd feel if you ate the best meal of your life at age 13, and the restaurant where you ate it went out of business the next day.

You'll be frustrated by all other software. You'll wander around trying to explain to other people why the thing you had was so good, and it was so easy, and that nothing else compares, and wouldn't it be great if everyone did things this way.

You have been warned.

Re:Why, oh why, do those nutheads use vi? by burke on Thursday February 02, 2012 @11:24AM (#3543300)
As someone who used emacs for five years before switching to vim, my personal experience was that the top-level comment is more true than this one.
Re:Why, oh why, do those nutheads use vi? by warp on Thursday February 02, 2012 @12:44PM (#3543707)
As someone who used emacs for 8 years, then swiched to vim and used that for 4 years, and then switched back to emacs 2 years ago -- my personal experience is that being forced to use anything which isn't vim or emacs will give me fits and make me cry, but switching from one to the other is mostly fine.
Re:Why, oh why, do those nutheads use vi? by chc on Thursday February 02, 2012 @02:02PM (#3543992)
As someone who always used graphical text editors with discoverable interfaces, for a long time I found both vi and emacs to be like black boxes covered in unlabeled fiddly knobs — except turning vi's knobs in the wrong order would make some of the other knobs start spinning wildly. Just trying to get either of them to use a color scheme that didn't hurt my eyes was an exercise in frustration. I can use either passably nowadays and do use both fairly frequently, but I have to admit I still find don't find either particularly nice to use. I feel like whatever is great about them is always hidden somewhere just out of sight.
Re:Why, oh why, do those nutheads use vi? by stock_toaster on Thursday February 02, 2012 @03:35PM (#3544312)
As someone who has used vim for many years, tried emacs a few times and was confused and disheartened, and continued to just use vim, I can provide no useful anecdotal evidence.

;)

Re:Why, oh why, do those nutheads use vi? by tikhonj on Thursday February 02, 2012 @09:33PM (#3545456)
That's because the Emacs comment missed Emacs's greatest feature: elisp. Adding functionality--even fairly complex functionality--to Emacs is much easier than extending any other editor I've used. Here are a couple of great examples from the last week for me:

I am currently taking a compiler course where we are implementing a particular language not entirely unlike--but not entirely like--Lua and Python. As part of the process, we need to churn out quite a bit of test code. Naturally, Emacs does not support this language by default because this language only exists as an implementation exercise for a couple of projects; however, creating a useful mode that does syntax highlighting and indentation--basically all you need to program comfortably--only took about 100 lines of code and less than an hour of programming!

Apart from my studies, I also work part-time at a startup. As part of this, I have to use and maintain a bunch of remote AWS machines that do all sorts of things: hosting, continuous integration, staging... I noticed that I was opening a lot of shells both locally and remotely. Writing up a command bound to a global key-stroke that prompts me for a name, opens a shell in the current directory (including remote directories!) and sets the prompt of the shell to its name literally took five minutes. And now I've saved a lot of time managing all my shells.

Being able to make my editor do exactly what I want with a trivial amount of effort is magical.

Re:Why, oh why, do those nutheads use vi? by cageface on Thursday February 02, 2012 @10:03PM (#3545529)
The deciding factor for me is that I can use the same basic Emacs keybindings in any other text entry widget, so my most central muscle memory translates to the shell, XCode, Firefox etc.

Vi/Vim is off in its own weird universe.

Re:Why, oh why, do those nutheads use vi? by burke on Thursday February 02, 2012 @10:34PM (#3545609)
I set up most of the emacs/OS X bindings in insert mode as well, and slowly migrated away from them toward more use of vim features. It eased the transition, and now I don't really feel any mismatch between the two.
Re:Why, oh why, do those nutheads use vi? by hencq on Thursday February 02, 2012 @11:47AM (#3543415)
Hehehe, yes I keep opening printer dialogs and new windows in my browser because of this. Though to be fair, that's often more due to being on Windows and not having 'focus follows mouse'.
Re:Why, oh why, do those nutheads use vi? by ludwigvan on Thursday February 02, 2012 @03:50PM (#3544390)
I think a lot of other editors (even in Visual Studio, Netbeans, Eclipse) have emacs keybindings though, so the situation is much better for an emacs user. It is much easier to implement due to modelessness of emacs.
Re:Why, oh why, do those nutheads use vi? by kahawe on Friday February 03, 2012 @05:28AM (#3546590)
"Ed is the standard text editor."
Re:Why, oh why, do those nutheads use vi? by andrewvc on Thursday February 02, 2012 @11:10AM (#3543215)
I just switched from ViM to emacs (mostly for SLIME) after about 6 years of ViM usage, it wasn't a big deal at all, both are great.
Re:Why, oh why, do those nutheads use vi? by sjs on Thursday February 02, 2012 @11:43AM (#3543394)
I use TextMate day to day. If I'm not on OS X I use Emacs for making software, and sometimes I use Emacs on OS X. It's great for JavaScript.

Though vim is no longer my main editor I still use it every day. Right tool for the job and all that.

Re:Why, oh why, do those nutheads use vi? by wahnfrieden on Thursday February 02, 2012 @01:48PM (#3543943)
Maybe you didn't use Vim with much depth? I know plenty of people who claim to use it but just stay in insert-mode all the time, don't use text-objects, etc. It doesn't really count if you actively avoid most things that make vim unique.
Re:Why, oh why, do those nutheads use vi? by anthonyb on Thursday February 02, 2012 @03:35PM (#3544314)
Maybe you shouldn't assume that people are morons?

---

Clarification, since I'm getting downvoted for that: Go look at the guy's profile, and his blog. He's an experienced dev, using vim for "6 years", and he's been on HN for three, has racked up a bunch of karma, blah, blah, blah. I'm pretty sure he got past the "use vim as notepad" stage. Assuming that he hasn't is assuming that he's a moron, and contributes nothing to the discussion.

How about you deal with the meat of what he's said? Something like "vim can do this thing which emacs can't" (unlikely) or "emacs does this annoying thing which vim doesn't" would be more productive than "Hey, I'm going to assume that you know nothing about vim, despite you using it for six years"

Actually, that's more of a rant than a clarification, but I'll let it stand.

Re:Why, oh why, do those nutheads use vi? by anthonyb on Thursday February 02, 2012 @10:27PM (#3545581)
Interesting; This comment has been voted up and down since I posted it, but nobody's yet answered with something that makes vim more annoying than emacs (or vice versa).
Re:Why, oh why, do those nutheads use vi? by tomjen3 on Thursday February 02, 2012 @11:07AM (#3543205)
But vi has been ported to just about anything, so why wouldn't you use it?
Re:Why, oh why, do those nutheads use vi? by rgraham on Thursday February 02, 2012 @02:25PM (#3544088)
Don't ever have a great experience when you're young. It'll ruin the rest of your life. Avoid it at all costs.

Or maybe you'll move on and it isn't that big of a deal.

You have been warned.

Re:Why, oh why, do those nutheads use vi? by artursapek on Thursday February 02, 2012 @11:38AM (#3543367)
But why do you stop using it in your scenario? Why does the restaurant have to go out of business?
Re:Why, oh why, do those nutheads use vi? by natesm on Thursday February 02, 2012 @11:47AM (#3543418)
Well, I use Xcode because the performance loss in writing Objective-C without autocompletion is larger than the performance gain from using vim. However, navigation is just so painful, and "awful" is really being kind about Xcode's find/replace.
Re:Why, oh why, do those nutheads use vi? by blinks on Thursday February 02, 2012 @02:13PM (#3544034)
Re:Why, oh why, do those nutheads use vi? by lftl on Thursday February 02, 2012 @11:51AM (#3543436)
Is there no suitable vim autocomplete script for Objective-C?
Re:Why, oh why, do those nutheads use vi? by weaksauce on Thursday February 02, 2012 @12:56PM (#3543742)
How well does the clang autocomplete work?

http://www.vim.org/scripts/script.php?script_id=3302

Re:Why, oh why, do those nutheads use vi? by weaksauce on Thursday February 02, 2012 @09:59PM (#3545524)
Cannot edit my comment but it works pretty well actually.

see:

http://imgur.com/6HQ13

quick lookup and a quick find as you type function. I like that if you press delete it will lookup the scope prior. so like if you type "addobj" and then delete a few times to "add" it will show you all the add commands again. Probably standard fare but not all implementations get this right.

Install was painless and I was able to map the invocation to ctrl-space, probably a better way to do it but I did it in a few seconds without looking anything up:

inoremap <c-space> <c-x><c-u>

Re:Why, oh why, do those nutheads use vi? by Riesling on Thursday February 02, 2012 @10:29AM (#3543020)
I feel your pain. This problem needs to be solved.

See my post below[0]. Your input would be appreciated.

[0]http://news.ycombinator.com/item?id=3543011

Re:Why, oh why, do those nutheads use vi? by singular on Thursday February 02, 2012 @10:04AM (#3542919)
s/vi/emacs/

;-)