From 02e17c1bc393c20276875eefe027f1d31a6877e5 Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Fri, 22 May 2015 11:36:16 +0200 Subject: reproducible: remove lockfiles older than 2 days --- bin/reproducible_maintenance.sh | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'bin/reproducible_maintenance.sh') diff --git a/bin/reproducible_maintenance.sh b/bin/reproducible_maintenance.sh index 34aca03a..5a2a5ec3 100755 --- a/bin/reproducible_maintenance.sh +++ b/bin/reproducible_maintenance.sh @@ -153,6 +153,15 @@ if grep -q '|' $PACKAGES ; then fi rm $PACKAGES +# remove lockfiles older than 2 days +LOCKFILES=$(find /tmp/reproducible-lockfile-* -maxdepth 1 -type f -mtime +2 -exec ls -lad {} \; || true) +if [ ! -z "$LOCKFILES" ] ; then + echo + echo "Removed old lockfiles:" + find /tmp/reproducible-lockfile-* -maxdepth 1 -type f -mtime +2 -exec rm -rv {} \; + echo +fi + # find packages which have been removed from the archive PACKAGES=$(mktemp) QUERY="SELECT name, suite, architecture FROM removed_packages -- cgit v1.2.3-54-g00ecf