Sharing the Vim clipboard along different Vim instances, even over the network.

Finding the solution

One day at work I told myself that should be out there a solution for this. I took a paper and start drawing those thoughts: what I have here are several computers connected in a private network, so perhaps I could have a vim server in my host master machine, and connect to that vim remote session from the virtual machines:

Why not to use a file for the yanked text?

This guy gave the solution: You select text in visual mode, and save it to a file in your system, then in another vim instance you can read that file pasting its content inside the current buffer. You map those actions in your .vimrc and then suddenly you can copy paste along different Vim instances. Cool!

--

--

Mountain Biker, swimmer and developer

Love podcasts or audiobooks? Learn on the go with our new app.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store