I would like to remap d in normal mode to “_d so that it doesn’t overwrite my yank buffer. I tried using
:nmap d "_d
but after doing that if I hit d my vim just dies and I can’t seem to input anything. Is there any better way to remap this?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You should never use
*mapwhen you can’t answer why you are prefering it to*noremap. Command that does not fall into infinite recursion isBy the way, yank buffer is
0, not"which is the default for pasting. Whiledoverrides", it does not do so to0.ythough overrides both"and0.