Sunday, October 20, 2013

Use :tjump instead of :tag in vim

Often when you press CTRL-] in vim there are several options to jump on. By default CTRL-] is mapped to :tag command, and you need to use :tselect after CTRL-] to see all alternatives. It is more convenient to see the list right away after pressing CTRL-]. vim already has such a command: :tjump. You just need to remap CTRL-] to :tjump instead of :tag:
nnoremap <c-]> g<c-]>
vnoremap <c-]> g<c-]>

nnoremap g<c-]> <c-]>
vnoremap g<c-]> <c-]>
Source.

No comments:

Post a Comment