3 ms·
I know im vim'ing wrong, but I just can't stop using arrow keys. Part of it is because I end up navigating around a little bit in insert mode sometimes, and swi
by jdc0589 8y ago
I know im vim'ing wrong, but I just can't stop using arrow keys. Part of it is because I end up navigating around a little bit in insert mode sometimes, and switching between arrow keys for insert mode ans hjkl for other modes seems dumb.
I don't have a problem using hjkl, I guess my problem is NOT needing to move around inside insert mode. Tips?
- furgooswft13 8y agoThe vim way is to simply escape out of insert mode, do your movement commands, then go back in. But you can also use ctrl+o [movement command] while in insert mode to do one-off movements and end up back in insert afterwards. I honestly don't think however that you betray any vim sacred cows by using the arrow keys, or even the mouse when they are convenient. Such as when in insert mode. hjkl is just much more convenient in normal mode while your hands are already in the right position.
- maxk42 8y agoiNavigating in insert mode is your problem.ESCo iThe default mode is called "normal mode" for a reason.ESC:wq
- richchurcher 8y agoAs furgooswft13 notes, you can use Ctrl-O <command> to issue single normal mode commands from insert mode. Most purists would say switch to normal mode to navigate, and by and large that's true (especially, IMHO, if you bind 'jk' to Esc which is much faster for a touch typist). However, insert mode does let you do this to avoid the arrow keys: inoremap <A-h> <Left> inoremap <A-l> <Right> inoremap <A-k> <Up> inoremap <A-j> <Down> Which some would say enforces 'bad' habits, but I reckon do whatever feels effective to you. If you do find yourself leaning on the direction keys for more than a few repeats, there's probably a faster way though!
- pull_my_finger 8y agoTry HardMode (https://github.com/wikitopian/hardmode https://github.com/wikitopian/hardmode) for vim. While it also disables some other stuff, the idea is it will force you to use the more efficient movement options.