I was trying to copy paste something from vim to another application and also, from that application to vim
using right click with mouse and then copy and paste (or with Ctrl+v and Ctrl+c and also tried the Command version for mac OSX, obviously.). However, when I try doing it, it only copies the first word when I do it from vim
or when I copy from the application to vim
, it copies everything, but inserts strange tabs and spaces. I think this happened when I decided to set my mouse on in the terminal. As in:
:set mouse=a
I have that line on my .vimrc
file on iTerm (mac os x). Though, is it possible to make my copy paste with other applications that are not in vim
not to break with the mouse=a
on? Or is it at least possible to set my mouse off while I do the copy paste? I did :help
mouse but the comments were not useful for me. I would paste them here but... my copy paste tool is broken!
I did try :set mouse!
and :set mouse=a!
but these did nothing useful... :(
Additional info of my environment:
I am also using tmux most of the time, though, I tested this error/bug without a tmux session, thats why I posted this mainly as a vim question.
vim
is capable of yanking to the Primary Selection just fine using they
verb. I don't know why you wouldn't just use that. – HalosGhost Jun 27 '14 at 19:44:set mouse=a
does not work properly with the native terminal. In fact it doesn't do anything as far as I can tell (so yes, copy pasting does seem to work in the native terminal) – Charlie Parker Jul 01 '14 at 01:38:set mouse=OFF
or something like that, that would be kind of a hack (not a "real" solution), but at least I would be able to copy paste by turning the mouse=off whenever I need to copy paste... – Charlie Parker Jul 01 '14 at 01:39mouse
commands*? Do you recall that far back? Thanks - I'll "owe you one" :) – Seamus Feb 06 '24 at 23:11