Restrict repetitive navigation keys and up/down arrow keys

1 Point

alex-netquity alex-netquity

10 years ago

I use this to force myself to navigate using combinations like 5j instead of jjjjj, eventually forming better navigation habits. It also disables the up and down arrow keys.

nmap jj :<C-u>echo 'Use nj!'<CR>
nmap kk :<C-u>echo 'Use nk!'<CR>
nmap <Down> :<C-u>echo 'Use nj!'<CR>
nmap <Up> :<C-u>echo 'Use nk!'<CR>