Redefining <leader> to previous mappings in vim
In vim :help leader
says that changing <leader>开发者_运维问答
after the moment that a mapping is defined does not change the mapping.
So how can I update my already mapping that used <leader>
with a new value of <leader>
??
Herbert gave the right answer: the <leader>
shall be defined in the .vimrc. We don't want a completely cumbersome procedure to change <leader>
on the fly. It's the same with <plug>
-mappings.
You will need to execute the mapping command again. If the mapping comes from a vimscript file, you will need to reload (:source
) it.
I guess it is useful because you won't need to edit mappings on vimcscripts that use <leader>
精彩评论