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

Once you get used to using vim properly, you'll find that you almost never need to move one character left or right (h or l). It is actually a nice setup that your index and middle fingers are responsible for moving up and down in the file since that is what you will be doing most often. There are much better ways of moving horizontally in the file than one character at a time. You can use w and b to move forward and backward via words which is much more efficient than single characters. You can also use f and F to 'find' a character forward or backward. I typically use that to navigate between method arguments or parentheses. So you can type f, and it will move your cursor FORWARD to the comma. Then just press ; to repeat the search (and go to the next comma). If you want to go backward, do F, and it works the same way, only backward. I'm sure there are better examples but the point is, if you are using h or l often, then there are probably better ways to navigate. Also, this sounds kind of confusing at first (having to remember fFwb; etc), but just learn one at a time and you won't have to think about it after a while. Soon you will find yourself typing an email and accidentally ending up with jjjjjj in random places... :)


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

Search: