Jared Smith's answer is generally correct, but here I'll provide a few more hints on how to implement this.
The very first thing you need to do, above all else, is to make sure you can touch-type (i.e., with your eyes closed) the entire keyboard, including numbers and punctuation. For example, you already know that going down one line and left five times is j5h
; you should not be looking at the keyboard for any of this. Many moves require the use of punctuation (e.g., paragraph forward/back }
/{
and search forward/back for word under cursor *
/#
), which is why you need to be able to touch-type this just as easily as you can hjkl
.
Learning this, if you don't already know it, will require slowing down before you can regain and exceed your previous speed. Like learning a scale on a musical instrument, you need to learn it correctly before you can do it correctly at speed.
Once you've got down these sorts of basic moves, move on to using counted basic moves that get you roughly closer to where you want to go when you need to do the move more than three or four times. 8wbb
is fewer keystrokes than hitting w
six times, and you'll be faster getting near where you need to go and then doing a small number of moves than you will trying to calculate a large count in advance.
At that point it's time to start adding new commands. Explore the Vim documentation (:help
), looking both at keystrokes you don't know to learn what's out there and at entire sections to see what's in the various command groups that can be helpful. As Jared says, pick something that seems the most useful and slow yourself down to start using it. Wait until you come back up to speed again with these new commands before trying to bring in more.
Once you've explored a fair number of Vim commands, you'll want to start examining what you're still inefficient on in your particular application and start adding mappings and functions to help you handle those. For example, I do a lot of markdown editing with references at the bottom of the file or section in which they're used; I've added gr
to search for the reference under the cursor (e.g., text like "[foo bar]") so I can easily move to other references and the reference definition. After using this for a while I added gR
to read the reference the cursor is one, jump to the reference definition, and copy the URL of the reference to the "+
buffer which lets me paste it directly into a browser, curl
command line, or whatever.
h
would be immediately to to the left of your right index finger's home position, should be easy to reach. Your comment about it being far makes me think you might be using a different layout? vim's keybindings are designed to be convenient for a standard QWERTY US keyboard, if you don't have that, I'm not surprised you're having a hard time.b
,B
,F
,T
or search (/
) instead?