summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2013-05-30 00:07:53 +0200
committerFlorian Pritz <bluewind@xinu.at>2013-06-03 21:47:01 +0200
commitf8ba9af8da1ce2570a50b7adadf67742829c71bf (patch)
tree270330b342e60aafe9507174c0be881ffc75cf3c
parent4ee34c7b9a53602f531f66683a87feb14051a1df (diff)
downloadbin-f8ba9af8da1ce2570a50b7adadf67742829c71bf.tar.gz
bin-f8ba9af8da1ce2570a50b7adadf67742829c71bf.tar.xz
sup: output status messages to stderr
Signed-off-by: Florian Pritz <bluewind@xinu.at>
-rwxr-xr-xsup8
1 files changed, 4 insertions, 4 deletions
diff --git a/sup b/sup
index e277e53..3ec84f5 100755
--- a/sup
+++ b/sup
@@ -12,7 +12,7 @@ times_ran=0
cleanup() {
if [ -n "$pid" ]; then
- echo "killed... $pid"
+ echo "killed... $pid" >&2
kill $pid
fi
exit
@@ -23,16 +23,16 @@ trap cleanup 2 15
while :; do
times_ran=$(($times_ran+1))
if [ $times_ran -gt $delay_after ]; then
- echo "sleeping for $delay seconds after $(($times_ran-1)) runs in $delay_reset_after seconds"
+ echo "sleeping for $delay seconds after $(($times_ran-1)) runs in $delay_reset_after seconds" >&2
sleep $delay
fi
time_started=`date +%s`
- echo -n "running... "
+ echo -n "running... " >&2
$command &
pid=$!
- echo PID: $pid
+ echo PID: $pid >&2
wait $pid
pid=""