Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VIM: Is there a way to make vim not copy whenever you delete text

Tags:

vim

I love vim, but one of my problems with it is that whenever I use x or d to remove text, it copies the deleted text into the buffer/clipboard.

More specifically, it's a problem when I have some text copied, and then I need to delete a second block of text before pasting the first text.

Is there a command that deletes text but does not copy it? If not, is there a custom command for this?

Thanks!

like image 768
Kyle Challis Avatar asked Mar 12 '14 20:03

Kyle Challis


1 Answers

Use black hole register

"_d

Setup your own mapping in vimrc like ,d to save some typing

like image 87
usha Avatar answered Oct 07 '22 00:10

usha