[Piuparts-devel] [Git][debian/piuparts][develop] only show meaningful busyness

Holger Levsen gitlab at salsa.debian.org
Tue Feb 5 20:13:05 GMT 2019


Holger Levsen pushed to branch develop at Debian / piuparts


Commits:
43c6c1a2 by Holger Levsen at 2019-02-05T20:12:55Z
only show meaningful busyness

Signed-off-by: Holger Levsen <holger at layer-acht.org>

- - - - -


1 changed file:

- slave-bin/slave_stop.in


Changes:

=====================================
slave-bin/slave_stop.in
=====================================
@@ -45,9 +45,12 @@ while pgrep --full '/usr/bin/python @sharedir@/piuparts/piuparts-slave' > /dev/n
 	echo -n "$(date -u +%T) - "
 	pgrep --full '/usr/bin/python @sharedir@/piuparts/piuparts-slave' | xargs -r echo -n "slaves running: "
 	SLEEP=$(( $i * $i ))
-	echo
-	echo "slaves are busy with:"
-	ps fax | grep -v grep | grep '/usr/bin/python @sbindir@/piuparts' | awk '{print $NF}'
+	if [ -n "$BUSY" ] ; then
+		# really/meaningful busy
+		echo
+		echo "slaves are busy with:"
+		BUSY=$(ps fax | grep -v grep | grep '/usr/bin/python @sbindir@/piuparts' | awk '{print $NF}')
+	fi
 	echo -n " sleeping ${SLEEP}sec now..."
 	for j in $(seq 1 $SLEEP) ; do
 		sleep 1



View it on GitLab: https://salsa.debian.org/debian/piuparts/commit/43c6c1a28dc77282334e4447ed8a03388063027d

-- 
View it on GitLab: https://salsa.debian.org/debian/piuparts/commit/43c6c1a28dc77282334e4447ed8a03388063027d
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/piuparts-devel/attachments/20190205/bff48d3a/attachment.html>


More information about the Piuparts-devel mailing list