Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Actually, 10. doesn't necessarily repeat the last command 10 times, it just runs it again with an argument of 10. For example ">>10." will indent the current line and then indent it and the following 9 lines.

I still haven't found an easy way to indent a line N times without pressing ">" 2N times...



Activate visual mode first. In visual mode, the argument is used for the number of indents (because the lines to indent are selected visually). So to indent the current line 4 times, type: "V4>". Happy vimming! :)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: