about summary refs log tree commit diff
path: root/swipeGuessPicker.sh
diff options
context:
space:
mode:
authorZach DeCook <zachdecook@librem.one>2022-01-24 23:31:25 -0500
committerZach DeCook <zachdecook@librem.one>2022-01-24 23:42:41 -0500
commit64ca6d5a0a77c633fb160bc2bbf76a3c1ec4c096 (patch)
tree07ed30ab7813328249336e2dbab2c9b1fe62bcd1 /swipeGuessPicker.sh
downloadSwipeBehaviors-64ca6d5a0a77c633fb160bc2bbf76a3c1ec4c096.tar.gz
swipeGuessPicker: new behavior method
Diffstat (limited to 'swipeGuessPicker.sh')
-rwxr-xr-xswipeGuessPicker.sh14
1 files changed, 14 insertions, 0 deletions
diff --git a/swipeGuessPicker.sh b/swipeGuessPicker.sh
new file mode 100755
index 0000000..e90f64e
--- /dev/null
+++ b/swipeGuessPicker.sh
@@ -0,0 +1,14 @@
+#!/bin/sh
+rm "$XDG_RUNTIME_DIR/sgp.sock"
+mkfifo "$XDG_RUNTIME_DIR/sgp.sock"
+cat 0<> "$XDG_RUNTIME_DIR/sgp.sock"|suggpicker 2>/dev/null|completelyTypeWord.sh &
+swipeGuess ~/.local/share/sxmo/words.txt 5 | while read -r word; do
+	set -- $word
+	if ! test "$2"; then
+		wtype "${1:1}"
+	else
+		echo "$word" > "$XDG_RUNTIME_DIR/sgp.sock"
+	fi
+done
+
+killall suggpicker