3 ms·
perhaps, I'm forgetting something, but these solutions seem overly complicated. I just have this in my .vimrc, and pasting (with formatting), is as simple as c
by phaedrix 15y ago
perhaps, I'm forgetting something, but these solutions seem overly complicated.
I just have this in my .vimrc, and pasting (with formatting), is as simple as copying text, going to vim and hitting 'p' in command mode.
for middle-click (system) clipboard:
:set clipboard=unnamed
for ctrl-c (X11) clipboard:
:set clipboard=unnamedplus
couple caveats:
* +xterm_clipboard
* 'unnamedplus' is only for >= 7.3.74
see here for more info http://vim.wikia.com/wiki/Accessing_the_system_clipboard http://vim.wikia.com/wiki/Accessing_the_system_clipboard
note: I used unnamedplus for a bit, but found it to be much less desirable than using the unnamed middle-click buffer...YMMV