From 1f44d74c080c168ccdb315f18a99f270f09c548d Mon Sep 17 00:00:00 2001 From: Anton Bobov Date: Sat, 21 Oct 2017 10:39:34 +0200 Subject: Update bin. + clipboard-stream: prints clipboard changes to stdout * ledger price db refactoring, added new xe --- clipboard-stream | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100755 clipboard-stream (limited to 'clipboard-stream') diff --git a/clipboard-stream b/clipboard-stream new file mode 100755 index 0000000..b4c1120 --- /dev/null +++ b/clipboard-stream @@ -0,0 +1,13 @@ +#!/bin/bash + +set -e + +recent_value=$(xclip -o -selection clipboard) +while true ; do + value=$(xclip -o -selection clipboard) + if [ "$recent_value" != "$value" ] ; then + recent_value=$value + echo $recent_value + fi + sleep 0.1 +done -- cgit v1.2.3