I want to map
vv to paste my highlighted text clipboard as opposed to vim's clipboard or the copy clipboard. Is this possible?
Note: This only applies in unix with X11 environments.
The "highlighted text" clipboard is known as the PRIMARY X selection (vs SECONDARY or CLIPBOARD X selections). Vim, when built with X support, provides access to the PRIMARY and CLIPBOARD selections via the registers
(you can find more information in
:help quoteplus and
So, to map pasting highlighted text, you might do something like this:
:nnoremap vv "*p
though, that mapping only saves one keystroke at the expense of toggling visual mode. You could just type