Saturday, November 8, 2014

Selectively using system clipboard from vim in iTerm2 (Mac)

I'm using vim 7.4 Huge version without GUI on Mac OS X 10.7. This
version is installed from Macports.

I launch it from iTerm2 and frequently from MC running in iTerm2 as
it is my default MC editor.

options include +clipboard, +python, -xterm_clipboard, -xterm_save.

With clipboard=unnamed I can copy to the system clipboard. However,
as it is configured now, that's too much of a good thing as any
delete (example ddp) ends up in the system clipboard and I want to
be able selectively copy to the system clipboard *without* using
visual mode (as opposed to selecting by mouse/trackball).

I've written quite a few simple vimscripts and I could do something
along the following lines :
1)set clipboard=unnamed
"" copy or cut and insert in sys clipboard
2)set clipboard=""

But I'd to inquire if there is something done already that might be
recommended. I'm happy to do my own work, but there is so many
better vimscripters out there ....

TIA
--
Tim
tim at tee jay forty nine dot com or akwebsoft dot com
http://www.akwebsoft.com, http://www.tj49.com

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment