diff options
author | Ben Boeckel <MathStuf@gmail.com> | 2011-03-10 21:09:03 -0500 |
---|---|---|
committer | Ben Boeckel <MathStuf@gmail.com> | 2011-03-10 22:32:50 -0500 |
commit | 5f2a6b9371fcf2ca78143cd255242e1cacac6ad1 (patch) | |
tree | 99ed27b7f261673b85c13bf222ed36b02d67cf76 /examples/data/scripts/follow.sh | |
parent | 8e1eee5059058a774ba3124ce18d5f0d52415202 (diff) |
Use printf rather than echo
Diffstat (limited to 'examples/data/scripts/follow.sh')
-rwxr-xr-x | examples/data/scripts/follow.sh | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/examples/data/scripts/follow.sh b/examples/data/scripts/follow.sh index ba1bab4..b038c12 100755 --- a/examples/data/scripts/follow.sh +++ b/examples/data/scripts/follow.sh @@ -9,18 +9,18 @@ shift # if socat is installed then we can change Uzbl's input mode once a link is # selected; otherwise we just select a link. if ! which socat >/dev/null 2>&1; then - echo "script @scripts_dir/follow.js \"@{follow_hint_keys} $keys\"" > "$UZBL_FIFO" + printf "script @scripts_dir/follow.js \"@{follow_hint_keys} $keys\"\n" > "$UZBL_FIFO" exit fi -result="$( echo "script @scripts_dir/follow.js \"@{follow_hint_keys} $keys\"" | socat - "unix-connect:$UZBL_SOCKET" )" +result="$( printf "script @scripts_dir/follow.js \"@{follow_hint_keys} $keys\"\n" | socat - "unix-connect:$UZBL_SOCKET" )" case $result in *XXXEMIT_FORM_ACTIVEXXX*) # a form element was selected - echo 'event FORM_ACTIVE' > "$UZBL_FIFO" + printf "event FORM_ACTIVE\n" > "$UZBL_FIFO" ;; *XXXRESET_MODEXXX*) # a link was selected, reset uzbl's input mode - echo 'set mode=' > "$UZBL_FIFO" + printf "set mode=\n" > "$UZBL_FIFO" ;; esac |