diff --git a/README.md b/README.md index a23717d..6789085 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -![Number of scripts](https://img.shields.io/badge/number_of_scripts-40-blue) +![Number of scripts](https://img.shields.io/badge/number_of_scripts-43-blue) # Random Scripts This repository is for random scripts I wrote mostly for personal use. diff --git a/get-remote-tmp-clipboard b/get-remote-tmp-clipboard new file mode 100644 index 0000000..6c210dc --- /dev/null +++ b/get-remote-tmp-clipboard @@ -0,0 +1,7 @@ +#!/bin/bash + +# This script should be used in conjunction with tmp-clipboard +# You need to pass a hostname to this script as an argument, and the script +# will pull the text saved by the remote machine's tmp-clipboard script + +ssh $* 'cat /tmp/.tmp-clipboard; >$_' | wl-copy diff --git a/tmp-clipboard b/tmp-clipboard new file mode 100644 index 0000000..c16f7ed --- /dev/null +++ b/tmp-clipboard @@ -0,0 +1,7 @@ +#!/bin/bash + +# This script just puts the piped text to a temp file +# Using the get-remote-tmp-clipboard script, we can retrieve it from another machine. + +cat >/tmp/.tmp-clipboard +