diff options
author | epoch <epoch@thebackupbox.net> | 2020-04-18 02:38:17 -0500 |
---|---|---|
committer | epoch <epoch@thebackupbox.net> | 2020-04-18 02:38:17 -0500 |
commit | e7019fb09653472bb57474638188dcba337f1a3c (patch) | |
tree | c0b1fb12c41cdaac57859929188a3476b7ad87d0 | |
parent | 9f5c79eff1a3fae473bbdd12afcb77875d8548af (diff) | |
download | hackvr-e7019fb09653472bb57474638188dcba337f1a3c.tar.gz hackvr-e7019fb09653472bb57474638188dcba337f1a3c.zip |
made the tee in hackvr_uri exit on a write error so that if you exit hackvr it'll stop the script
-rwxr-xr-x | bin/hackvr_uri | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/hackvr_uri b/bin/hackvr_uri index 7907d9b..19c0f37 100755 --- a/bin/hackvr_uri +++ b/bin/hackvr_uri @@ -1,6 +1,8 @@ #!/bin/bash #this is a version of hackvr that will attempt to launch URIs that your user actions on. -hackvr \ +set -o pipefail +tee --output-error=exit /dev/stderr | hackvr \ + | grep --line-buffered -v '^#' \ | tee \ >(sed -un "s/$USER *action *<\([^ ]*\)>/\1/p" \ | stdbuf -o0 tr '\n' '\0' \ |