Skip to content

Instantly share code, notes, and snippets.

View solaris9000's full-sized avatar

Solaris9000 solaris9000

View GitHub Profile
@solaris9000
solaris9000 / vim_tmux_no_X_clipboard.vim
Created February 8, 2022 21:05 — forked from TroyFletcher/vim_tmux_no_X_clipboard.vim
Sharing clipboards between vim and tmux without xsel or xclip or X forwarding
" Share clipboards between vim and tmux without xsel or xclip (which require X and
" X forwarding with SSH) and without changing tmux shortcuts. Requires only tail.
"
" Great for an ssh session to you linode or droplet.
"
" Uses z buffer in vim and writes output to ~/.clipboard and then to tmux's paste
" buffer, and reads it back in cleanly for putting (puddin').
"
" NOTE: tmux has an undocumented command limit! https://github.com/tmux/tmux/issues/254
" this means if you mean to copy larger bits of code (entire functions) tmux will