4 ms·
I use vim and don't miss the mouse; I don't even have a scroll wheel (I much prefer a proper old fashioned 3-button mouse with a proper middle button). A tags
by maskros 10y ago
I use vim and don't miss the mouse; I don't even have a scroll wheel (I much prefer a proper old fashioned 3-button mouse with a proper middle button).
A tags file and ^] and ^t to navigate is faster than file browsing and scrolling around. * and # to quickly jump between instances of the same token. ^6 to quick swap between buffers, and ^o and ^i to quickly jump back and forth between locations I've visited.
Fast cursor movement using b, w, {, }, /search, [[, ]], is also much faster than mousing around or slowly navigating using arrow keys.
Scrolling is done by ^e and ^y, and zz to center on the cursor. Faster than a scroll wheel.
And don't forget the almighty '.'. To quickly replace a variable name, stand on the variable, hit * to search for it and remember the search. Then 'cw' to change a word, type the new name, hit escape. Then 'n.' to find the next instance and repeat the edit.
- dghf 10y agoAnd this is why I read vim threads. I've been using vim for years, yet didn't know about ^O, ^I, ^E, ^Y or ^^. That last in particular is going to be a big help. No more `:e #` for me!
- maskros 10y agoWhile doling out vim tips, here are two quality of life improvements you can add to your .vimrc: nmap ; : set grepprg=git\ grep\ -n nmap <F7> :cp<CR> nmap <F8> :cn<CR>
- dghf 10y agoAh, I'm one of those weirdos who actually uses ; (and ,). Though I guess I could noremap ; : noremap : ; But that might take muscle memory too much time to adapt. (And would it break plugins?) I've already got F7 and F8 mapped, but I'll hunt out a spare key(sequence) for the mappings you suggest.