diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2012-06-10 11:45:59 +0200 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2012-06-10 11:45:59 +0200 |
commit | c639ae7d7a9fa5544d495e0b4d4f3b49611a7af9 (patch) | |
tree | 58ecd32687a218371840b82aa9f8906148ecb724 /cron-jobs | |
parent | 75a16bafa3d79499af710414c57ff50451b158a3 (diff) | |
download | dbscripts-c639ae7d7a9fa5544d495e0b4d4f3b49611a7af9.tar.gz dbscripts-c639ae7d7a9fa5544d495e0b4d4f3b49611a7af9.tar.xz |
Remove support for packages in legacy $repo/os/any directories
Diffstat (limited to 'cron-jobs')
-rwxr-xr-x | cron-jobs/ftpdir-cleanup | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/cron-jobs/ftpdir-cleanup b/cron-jobs/ftpdir-cleanup index 9bc88d7..15eb46c 100755 --- a/cron-jobs/ftpdir-cleanup +++ b/cron-jobs/ftpdir-cleanup @@ -75,29 +75,6 @@ if [ ${#old_pkgs[@]} -ge 1 ]; then done fi -# cleanup of legacy $repo/os/any directories -for repo in ${PKGREPOS[@]}; do - if [ ! -d "${FTP_BASE}/${repo}/os/any" ]; then - continue - fi - if [ -n "$(find "${FTP_BASE}/${repo}/os/any" -type d -empty)" ]; then - msg "Removing empty legacy directory ${repo}/os/any" - ${CLEANUP_DRYRUN} || rmdir "${FTP_BASE}/${repo}/os/any" - continue - fi - find "${FTP_BASE}/${repo}/os/any" -name "*${PKGEXT}" -printf '%f\n' | sort > "${WORKDIR}/any-${repo}" - cat "${WORKDIR}/db-${repo}-"* | sort -u > "${WORKDIR}/all-${repo}" - - old_pkgs=($(comm -23 "${WORKDIR}/any-${repo}" "${WORKDIR}/all-${repo}")) - if [ ${#old_pkgs[@]} -ge 1 ]; then - msg "Removing old packages from [${repo}] (any)..." - for old_pkg in ${old_pkgs[@]}; do - msg2 "${old_pkg}" - clean_pkg "${FTP_BASE}/${repo}/os/any/${old_pkg}" - done - fi -done - old_pkgs=($(find ${CLEANUP_DESTDIR} -type f -name "*${PKGEXT}" -mtime +${CLEANUP_KEEP} -printf '%f\n')) if [ ${#old_pkgs[@]} -ge 1 ]; then msg "Removing old packages from the cleanup directory..." |