jooize / vim-colemak

Colemak key mappings for Vim. Consider using Coleremak instead.
203 stars 50 forks source link

Turbo navigation #4

Open jooize opened 8 years ago

jooize commented 8 years ago

Turbo navigation (HNEI=5*hjkl) was removed in https://github.com/jooize/vim-colemak/commit/c057ed04075cab3f0a67c0fdc30c9d2f35621eff. I felt it didn't make sense as default mappings in Vim, and I would rather free up the keys for custom uses.

I considered adding an option, but decided not to because I didn't want to commit to having it in forever. Please write any arguments for and against.

You can add the following to your .vimrc to use turbo navigation again.

" Turbo navigation (Colemak) {{{
    " Works with counts, see ":help complex-repeat"
    nnoremap <silent> H @='5h'<CR>|xnoremap <silent> H @='5h'<CR>|onoremap <silent> H @='5h'<CR>|
    nnoremap <silent> N @='5gj'<CR>|xnoremap <silent> N @='5gj'<CR>|onoremap <silent> N @='5gj'<CR>|
    nnoremap <silent> E @='5gk'<CR>|xnoremap <silent> E @='5gk'<CR>|onoremap <silent> E @='5gk'<CR>|
    nnoremap <silent> I @='5l'<CR>|xnoremap <silent> I @='5l'<CR>|onoremap <silent> I @='5l'<CR>|
" }}}

I found myself abusing turbo navigation instead of learning to move using long-term more useful ways, but that doesn't feel like a strong argument against the feature.

jamischarles commented 8 years ago

I do use this a lot (up and down mainly). Thanks for showing how to add it back in here.

jamischarles commented 8 years ago

If you're going to keep it out, I'd suggest adding this snippet to the readme :)

ghost commented 8 years ago

I personally used the turbo navigation a lot, although I also agree with adding a "common extras" section to the readme that points this out.

jooize commented 8 years ago

Thanks for your feedback!

Added it to the readme in https://github.com/jooize/vim-colemak/commit/4d3592722d067f4486a1ec360ca0d57b13d35f9f.