1
0
Fork 0
mirror of https://github.com/sbrl/bin.git synced 2018-01-10 21:33:46 +00:00
bin/listenclip

12 lines
288 B
Bash
Executable file

#!/usr/bin/env bash
### Settings ###
# The port number to listen on.
PortNumber=5556;
################
echo Clipboard listening on localhost:$PortNumber.
echo Press CTRL+C to quit.
while (true); do nc -l $PortNumber | xclip -selection c; echo Local clipboard set by remote host.; done