I have Vim inside Tmux. When I copy text using yy
and paste. I get the following error E353: Nothing in register *
.
This issue only happens when using Vim 7.4. However, when using Vim outside of Tmux, this issue does not occur.
On a sidenote, this does not happen when using Vim 7.3 (vim version installed by OSX 10.9), inside or outside of Tmux.
In .vimrc
, I have:
set clipboard=unnamed
In .tmux.conf
, I have:
set-option -g default-command "reattach-to-user-namespace -l bash"
When using Vim under Windows, the clipboard can be accessed with the following: In step 4, press Shift+Delete to cut or Ctrl+Insert to copy. In step 6, press Shift+Insert to paste.
Pasting in VimOnce you have selected text in Vim, no matter whether it is using the yank or the delete command, you can paste it in the wanted location. In Vim terminology, pasting is called putting and the function is utilized with the p command. Using this command pastes the selected text after the cursor.
You can copy this sentence on this blog. Copy and Paste should now work in nvim if the above commands execute to what we've specified above. Let's go into nvim and try it. Just open up nvim and do a "+ you will see the contents of the system clipboard get pasted into the buffer.
In my case I just got it fixed by including on .tmux.conf
the following configuration:
set -g default-command 'reattach-to-user-namespace $SHELL --login'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With