I want to remap Ctrl+y(scroll up) to up.
However, I also have yankring mapped to Ctrl+y, and I wish to keep yankring's mapping.
Now if I have this in .vimrc: map <Up> <C-y>, pressing up will trigger yankring.

So is there a way to remap Vim's default key mapping (or map to it's function), whilst having plugin mapped to it?


Try: noremap <up> <c-y>

Regular key maps are recursive, meaning they will invoke your other defined key maps. noremap makes it so that the {rhs} uses the default key maps.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.