]> git.llucax.com Git - personal/ion3-config.git/blobdiff - psi_status.sh
Bugfix: remove \n's to psi_status.sh output so statusd don't get confused.
[personal/ion3-config.git] / psi_status.sh
index f68de5b1c38b725b2b65ac6909d745d661704c9e..9a270593d661f60aaaef0c4e98307d7a39f86fe9 100755 (executable)
@@ -7,7 +7,10 @@ regex='^\s*<jid'
 
 msgs=`egrep "$regex" $events_files | wc -l`
 jids=`egrep "$regex" $events_files \
 
 msgs=`egrep "$regex" $events_files | wc -l`
 jids=`egrep "$regex" $events_files \
-               | sed 's/.*<jid>\(.*\)<\/jid>.*/\1/' | sort -u`
+               | sed 's/.*<jid>\(.*\)<\/jid>.*/\1/' \
+               | sort -u \
+               | tr '\n' ' ' \
+               | sed 's/ $//'`
 if [ $msgs -eq 0 ]
 then
        echo "nada nuevo"
 if [ $msgs -eq 0 ]
 then
        echo "nada nuevo"