|
ci" deletes the inside of parentheses I think you mean inside quotes, by the way. I find the idea that there are 100 vim commands every programmer should know a but ludicrous though. Especially considering that the "100" commands were all compositions of simpler vim commands anyways. I don't think this is actually that great a submission, for this reason. How many ways are there to rehash some really specific example -- say, counting both ":set syntax [on|off]"? Vim is so much more general than that. It seems inaccurate -- even discourteous -- to treat this as some laundry list of commands in your bag of tricks (except in the case of, say, muscle memory). From my experience, you don't memorize some long string of letters as a command; you think of what each tiny bit does in and of itself, then compose that into whatever you want to accomplish. Rather than commit the string "ggguG" to your brain, vim users think of it as "go to the beginning of the file (gg), then uppercase (gu) to the end of the the file (G)". Granted, vim gets more complicated as you delve into the realm of motions, .vimrc level configurations, ex command line, etc. Also, it seems that vim users would be the real ones who need to know such things, not every programmer altogether. The title feels cheap / sensationalized that way. If there were some REAL list of vim commands "every programmer should know" (well, vim-user), I'd at least start by recommending the alphabet... |
That said, I up-voted this submission solely because it's showing off Vim. That's what I try to do with the programmers I meet -- evangelize about Vim.
I'll never forget the first time I saw an ancient Vim user hacking away at code. It seriously blew me away, and I knew that I had to learn it. Via a combination of :help and O'Reilly's "Learning the Vi Editor", I learned. Four years later (and that's young for a Vim user), I'll never look back.
Point being: you can't learn via a cheat sheet. Dive into Vim, starting from the basics.