aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2016-12-19 12:02:48 -0200
committerSilvio Rhatto <rhatto@riseup.net>2016-12-19 12:02:48 -0200
commit2a702bb52842229d8d3e1ad010c92ad810feee15 (patch)
tree9571dadb08ecb3d6dd2881cf2962a31d9b2ed8a2
parentc763dea94d8884b6bb54b94b44b987853aafa87f (diff)
downloadkeyringer-2a702bb52842229d8d3e1ad010c92ad810feee15.tar.gz
keyringer-2a702bb52842229d8d3e1ad010c92ad810feee15.tar.bz2
Fixes sclip and adds XDOTOOL_NEXT_WINDOW config
-rwxr-xr-xlib/keyringer/actions/sclip9
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/keyringer/actions/sclip b/lib/keyringer/actions/sclip
index e4c88fa..a941fd0 100755
--- a/lib/keyringer/actions/sclip
+++ b/lib/keyringer/actions/sclip
@@ -11,13 +11,18 @@ source "$LIB" || exit 1
shift
keyringer $KEYRING xclip $*
+# Se window switch combo
+if [ -z "$XDOTOOL_NEXT_WINDOW" ]; then
+ XDOTOOL_NEXT_WINDOW="alt+Tab"
+fi
+
# Move to the next window
if which xdotool &> /dev/null; then
- xdotool key alt+Tab
+ xdotool key $XDOTOOL_NEXT_WINDOW
fi
# Sleep
sleep 5
# Overwrite clipboard
-cat $RANDOM | sha256sum | base64 -d | xclip
+echo $RANDOM | sha256sum | base64 -d | xclip