admin: distfiles/cleaner/lister - proper set substraction

baggins baggins at pld-linux.org
Wed Apr 26 19:12:32 CEST 2006


Author: baggins                      Date: Wed Apr 26 17:12:32 2006 GMT
Module: admin                         Tag: HEAD
---- Log message:
- proper set substraction

---- Files affected:
admin/distfiles/cleaner:
   lister (1.1 -> 1.2) 

---- Diffs:

================================================================
Index: admin/distfiles/cleaner/lister
diff -u admin/distfiles/cleaner/lister:1.1 admin/distfiles/cleaner/lister:1.2
--- admin/distfiles/cleaner/lister:1.1	Wed Apr 26 18:06:03 2006
+++ admin/distfiles/cleaner/lister	Wed Apr 26 19:12:27 2006
@@ -74,6 +74,12 @@
 rm -f $LISTFILES
 
 $D=$(date +%Y-%M-%d)
-sort active-list-distfiles full-list-distfiles | uniq -u >distfiles-remove-$D
+# List only files that are in full-list-distfiles but
+# not in active-list-distfiles
+# Just uniq -u is not enough because you can remove files added during
+# run of the script
+# B\(A * B)
+sort active-list-distfiles full-list-distfiles | uniq -d | \
+	sort - full-list-distfiles | uniq -u >distfiles-remove-$D
 
 cvs commit -m"- $D update" active-list-distfiles verified-specs-tags
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/admin/distfiles/cleaner/lister?r1=1.1&r2=1.2&f=u



More information about the pld-cvs-commit mailing list