Clipd is a small Go utility that lets a Linux machine send clipboard text and run programs on a Windows machine over a local network.
- Sends clipboard text from Linux to Windows.
- Runs a Windows program with arguments.
- Pipes stdin to a Windows program.
- Resolves Linux paths to Windows drive paths using a mapping table.
- Client built from
cmd/clipdruns on Linux. - Server built from
cmd/serverruns on Windows and listens for requests.
Use Mage to build the binaries into the bin directory.
mage BuildOn Linux this builds bin/clipd.
On Windows this builds bin/clipd.exe and bin/server.exe.
Clipd reads a JSON config file at ~/.clipd on both Linux and Windows. Values support environment variable expansion.
{
"serverIP": "192.168.1.10",
"serverPort": 5454,
"password": "secret",
"driveMappings": {
"C:": "/mnt/c",
"D:": "/mnt/d"
}
}Send clipboard text from Linux to Windows:
echo hello | clipdResolve a Linux path to a Windows path:
clipd path ~/projects/demoRun a Windows program:
clipd run notepad.exePipe stdin to a Windows program:
printf "text" | clipd pipe clip.exeRequests are plain JSON over the network, so use it on a trusted network.