svermeulen / vim-easyclip

Simplified clipboard functionality for Vim
689 stars 21 forks source link

Clipboard sharing broken: yankstack file could not be written with multiple vim instances open. #122

Open simlei opened 6 years ago

simlei commented 6 years ago

With another vim instance open, this occurs:

Error detected while processing function EasyClip#Yank#YankMotion[5]..EasyClip#Yank#_YankLastChangedText[29]..EasyClip#Yank#OnYanksChanged[3]..EasyClip#Shared#SaveToFileIfDirty:      
line   19:
E482: Can't create file /home/simon/touchstone/modules/vim/unmanaged/easyClipShareYanks/.easyclip

I have set:

let g:EasyClipShareYanksDirectory = g:UnmanagedDataFolder('easyClipShareYanks') " has its own var for specifying filename
let g:EasyClipShareYanks = 1

I quote the doc: EasyClip can automatically store the yank history to file, so that it can be restored the next time you start Vim. Storing it to file also allows other active Vim instances to seamlessly share the same clipboard and yank history.

simlei commented 6 years ago

I have set other flags as well, but strictly by the book i.e. :h easyclip suggestions. For example, I am using the suggested x mapping for "cut".