index : builder | |
Archlinux32 build system | gitolite user |
summaryrefslogtreecommitdiff |
author | Erich Eckner <git@eckner.net> | 2018-05-25 19:20:12 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2018-05-25 19:20:12 +0200 |
commit | 7f1100ee43c2628277d4affd51d604a816835958 (patch) | |
tree | eb637e93ead88608bca4acdc96ec438e9bd6592a | |
parent | 3c9fe12e3eaf882e49c7498cc0344d24c1a0ae58 (diff) |
-rwxr-xr-x | lib/common-functions | 3 |
diff --git a/lib/common-functions b/lib/common-functions index 50dc6f1..7fe91ef 100755 --- a/lib/common-functions +++ b/lib/common-functions @@ -126,8 +126,6 @@ ls_master_mirror() { remove_old_package_versions() { -# TODO: needs to remove binary_packages_in_repositories, too - ( # the new shell is intentional tmp_dir=$(mktemp -d 'tmp.common-functions.remove_old_package_versions.XXXXXXXXXX' --tmpdir) trap 'rm -rf --one-file-system "${tmp_dir}"' EXIT @@ -230,6 +228,7 @@ remove_old_package_versions() { printf 'CREATE TEMPORARY TABLE `del` (`id` BIGINT NOT NULL AUTO_INCREMENT, PRIMARY KEY (`id`));\n' printf 'LOAD DATA LOCAL INFILE "%s" INTO TABLE `del` (`id`);\n' "${tmp_dir}/db-removes" printf 'DELETE `binary_packages` FROM `binary_packages` JOIN `del` ON `binary_packages`.`id`=`del`.`id`;\n' + printf 'DELETE `binary_packages_in_repositories` FROM `binary_packages_in_repositories` JOIN `del` ON `binary_packages_in_repositories`.`package`=`del`.`id`;\n' } | \ mysql_run_query fi |