The vim * and + system registry does not work

:echo has('clipboard') returns 1, but whenever I execute "+yy" or "*yy" nothing looks like in these registers. If I use plain yy to copy another line of text, try pasting from the register using CONTROL+V nothing will happen. If I try, "+p vim inserts a line of text that I copied using the regular yy command.

What's going on here? By the way, I'm on FreeBSD.

+6
source share
1 answer

If you have something to copy to the clipboard and paste into vim, you can use "+p .

+ is quoteplus, which means CLIPBOARD documented choice of X :help quoteplus for more information.

If you want to copy something in vim to the clipboard and paste the contents to another location Ctrl+v , you can do "+yy , this will copy the current line to the clipboard.

Additional information about the vim register:

 :help registers :help quotestar 
+2
source

Source: https://habr.com/ru/post/952296/


All Articles