Live data from Hacker News

VIM Pays Excellent Dividends: Learn it early, if you can

medium.com

51–60 of 65 posts

Re: VIM Pays Excellent Dividends: Learn it early, if you can

#51
post #15

I've used vim and emacs. I can't claim to be an expert on either, but I am somewhat comfortable with vim and it can be convenient for any unix straight out of the box. But I found it to be fairly overrated even with all these claims of boost in productivity. Just use Sublime Text in this day and age and use the spare time you would've had to learn vim and do something more useful.

I've always been wondering if there is some secret that I've been missing and that these VIM or Emacs gurus keep to themselves which makes them "more productive". All these abstract claims in blog posts and on forum pages about productivity are completely worthless. Go watch a stream where you can actually see someone program. Maybe you'll pick something up that they do better/faster/more elegant than you. Other than…

I also was rather sceptical wrt Vim at first; the only reason I ever started using it was that I needed a text editor that compiled for ARM architectures (I wanted to use it in a chroot on my chromebook). After a couple of hours the distrust got to "hm, this might not be too bad". After a couple of days I switched my ZSH to Vim bindings. Now I even use pentadactyl/qutebrowser for browsing the web.

The whole "Vim gives me amazing productivity" thing seems to be a personality trait: People telling you this are much more positive wrt tooling than I am. My basic gist is more like "why the hell can't I do X with this tool". I only started recognizing Vim's worth after getting more and more frustrated at other tools because they seemed to slow me down. Funny enough, I had the exact same experience a couple of years earlier after I got reasonably accustomed with Linux and Bash/ZSH. Learning them was more or less "meh", but coming back to Windows is a nightmare for me now. You have to do everything via the mouse, and the terminal seems almost unusable for me - it's not that I am amazed at how great my tools are (which, to be fair, they actually are), but I get very angry at any tool that doesn't at least do a decent job.

Luckily for me, this effect only seems to affect my experience with tools. I still can get very excited about APIs and programming paradigms :-)

Re: VIM Pays Excellent Dividends: Learn it early, if you can

#52
post #44
post #38

Earlier quoted context omitted.

You should give spacemacs a look: vim mode in emacs plus all the stuff you are missing from the other editors. I don't use it because I am a happy vim user and more recently vscode using vim mode : the best of both worlds.

I've never used emacs, so it's not immediately obvious to me how that's better. I'll give it a shot though, thanks for the recommendation.

It's spacemacs. Google spacemacs.

Re: VIM Pays Excellent Dividends: Learn it early, if you can

#53

When I read articles about vi/vim being great for coders I always wonder how you deal with having to use the same part of your brain for writing the code you are writing and to "code vim commands" I mean, I understand it's attractive to a programmer's mind to be able to do fancy 'replace the next 3 words with x' and so on, and compose them in vim's language, but if I am deep in an algorithm the last thing I want is t…

This is a great point that I wish I wrote about.

I think this is actually the source of the "steep learning curve" problem. Once you've used it enough, it is an almost orthogonal part of your brain that does thats the VIM command-ing. It becomes more like, "to walk, put one foot in front of the other." You don't actually process that thought when walking.

But, until that point, it absolutely IS the same part of your brain. Until that point, there IS a PAINFUL contention between work brain and editor brain.

Re: VIM Pays Excellent Dividends: Learn it early, if you can

#54
agreed, 100%. I used to be a GUI diehard. Then, I was told about emacs and became an emacs fanatic. But the difference between emacs and vi/vim is that you can count on vim not only being on any system anywhere, but behaving in almost the exact same way anywhere.

vim is timeless.

Re: VIM Pays Excellent Dividends: Learn it early, if you can

#55

When I read articles about vi/vim being great for coders I always wonder how you deal with having to use the same part of your brain for writing the code you are writing and to "code vim commands" I mean, I understand it's attractive to a programmer's mind to be able to do fancy 'replace the next 3 words with x' and so on, and compose them in vim's language, but if I am deep in an algorithm the last thing I want is t…

> I always wonder how you deal with having to use the same part of your brain for writing the code you are writing and to "code vim commands"

I think the transformations you think about map very nicely to vim commands. If you want to move some code around for instance, the action you want in the brain is "delete line" and the vim mapping is "dd". So I'm never thinking about vim commands, I just have an internal mapping for the change I want to the command to do it.

This is where I find the productivity comes from, with a normal editor you go thought->action, thought->action, etc and I find if action is to long it can break the thought part.

Re: VIM Pays Excellent Dividends: Learn it early, if you can

#56
post #52
post #44

Earlier quoted context omitted.

I've never used emacs, so it's not immediately obvious to me how that's better. I'll give it a shot though, thanks for the recommendation.

It's spacemacs. Google spacemacs.

> vim mode in emacs

My reply was in context of that; since I have never used emacs, it wasn't immediately apparent to me what spacemacs might be like. I will, of course, Google spacemacs. :-) thanks for the tip

Re: VIM Pays Excellent Dividends: Learn it early, if you can

#57
I'm a diehard Vim fan. I use Vi-motion keybindings everywhere. System-wide. In every single tool I use. I don't ever touch arrow keys. I don't need to. I rarely have to use touchpad. It feels empowering to be able to do things the way I do. I don't think anymore about how and what I need to do to get quickly where I want to be - I just intuitively do it. This is probably how controlling things with your mind would feel. The downside? I can't work using one hand anymore. It just feels weird.

Vim is awesome. It's not an editor - it's a lifestyle. It's telling the machine who's the boss. It's staying "in the zone". It's cutting through the code like slicing butter with hot knife.

So, one day I woke up. I realized that Emacs can be better Vim than Vim. Hold on. Before throwing stones at me do one thing: give an honest and heartfelt try to Spacemacs. I guarantee it - you will be amazed.

Re: VIM Pays Excellent Dividends: Learn it early, if you can

#58

I've used vim and emacs. I can't claim to be an expert on either, but I am somewhat comfortable with vim and it can be convenient for any unix straight out of the box. But I found it to be fairly overrated even with all these claims of boost in productivity. Just use Sublime Text in this day and age and use the spare time you would've had to learn vim and do something more useful.

I've been thinking about this lately, and whether my preference for modal editors is a historical accident, an adaptation to the limited resources available when I was an undergrad, or whether there's more to it. I think there's more to it. What separates vim and emacs from editors with a more forgiving learning curve is that they embrace a separate language for editing that's distinct from text entry. That's not to…

I wonder if that's the feeling too if you come back to a "normal" programming language after getting reasonably proficient in Lisp.

I see a couple of interesting parallels there - the biggest difference of Vim's modal commands to other control schemes (except maybe Emacs') is that they compose rather well. Add macros to that, and you can define (more or less) abstract editing functionality on the fly. It's basically a similar thing to what Lisp did to ASTs with it's homoiconicity and the macro system on top of it...

Re: VIM Pays Excellent Dividends: Learn it early, if you can

#59
post #43

Earlier quoted context omitted.

> I have been using pathogen since I started using vim Thanks for the recommendation. The trouble (and again, maybe this is down to my lack of research) is that other commenters will recommend Vundle with links to similar resources (and I've tried both Vundle and Pathogen, sometimes one after another, ruining my ~/.vim dir :P). I can find all of these recommendations myself but (maybe I'm wrong here) there's no clear…

Watch this three minute video or view the concise notes below it for some very nice tips on handling buffers. http://vimcasts.org/episodes/working-with-buffers/ > You can quickly jump between the active buffer and the alternate buffer using the command . Pressing it again takes you back to where you were before. If you don't like the command for this, you could map it to something else, such as the tab key, with a li…

Thanks, that video was pretty good and helped me understand buffers. If you'll indulge me a bit more though, why does Vim warn you while switching out of an unsaved buffer (and make you use !) if it's still going to keep your changes when you come back?

> However, the latest release of Vim now includes a built in plugin system, does that satisfy your need to have one blessed version?

It absolutely does. I'm going to try it out!

Post reply on HN