diff --git a/autodist-cleanold b/autodist-cleanold index 20e08ca..e2ae5f9 100755 --- a/autodist-cleanold +++ b/autodist-cleanold @@ -20,7 +20,7 @@ function clean() { if [ -e $dir/RPM/BUILD/ ]; then find $dir/RPM/BUILD/ -mindepth 1 -maxdepth 1 -type d -ctime ${BUILD_CTIME_OLD} -exec rm -rf {} \; # delete older package duplicates - find $dir/RPM/BUILD/ -maxdepth 1 | sort -V | \ + find $dir/RPM/BUILD/ -maxdepth 1 | grep -V SPECPARTS | sort -V | \ while read curr; do if [ "${curr/-[0-9._]*}" = "${last/-[0-9._]*}" -a "${last}" ]; then rm -rf $last