[Piuparts-commits] [SCM] piatti.debian.org configuration files branch, develop, updated. 667026c0d14acb79c112ea444a1b20d4d0c00a8c

Holger Levsen holger at layer-acht.org
Wed Dec 21 15:15:08 UTC 2011


The following commit has been merged in the develop branch:
commit 667026c0d14acb79c112ea444a1b20d4d0c00a8c
Author: Holger Levsen <holger at layer-acht.org>
Date:   Wed Dec 21 16:15:03 2011 +0100

    only cause output if there is meaningful output

diff --git a/home/piupartsm/bin/archive_old_logs b/home/piupartsm/bin/archive_old_logs
index ad6d9aa..fcbf8c1 100755
--- a/home/piupartsm/bin/archive_old_logs
+++ b/home/piupartsm/bin/archive_old_logs
@@ -1,6 +1,6 @@
 #!/bin/sh
 
-# Copyright 2009-2010 Holger Levsen (holger at layer-acht.org)
+# Copyright 2009-2011 Holger Levsen (holger at layer-acht.org)
 # 
 # This program is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by the
@@ -44,7 +44,6 @@ get_config_value SECTIONS global sections
 # archive old log files
 #
 for SECTION in $SECTIONS ; do 
-	echo $SECTION
 	mkdir -p $MASTER/$SECTION/archive
 	cd $MASTER/$SECTION
 	mkdir -p archive/pass archive/bugged archive/fail
@@ -55,6 +54,7 @@ for SECTION in $SECTIONS ; do
 		# all logs except the last one (|sed '$d' deletes the last line)
 		OLDLOGS=$( ls -tr1 --color=none bugged/${PACKAGE}_*.log fail/${PACKAGE}_*.log pass/${PACKAGE}_*.log 2>/dev/null|sed '$d' )
 		if [ ! -z "$OLDLOGS" ] ; then
+			echo $SECTION
 			for LOG in $OLDLOGS ; do
 				mv -v $LOG archive/$(echo $LOG|cut -d"/" -f1)/
 			done

-- 
piatti.debian.org configuration files



More information about the Piuparts-commits mailing list