diff options
author | Erich Eckner <git@eckner.net> | 2018-01-29 08:50:36 +0100 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2018-01-29 08:50:36 +0100 |
commit | 9dc2f0416b3865298a86815d5d18b59a6a50d471 (patch) | |
tree | dfaae6e56aa98b3c002e0bb249e95c7ac4fb7b8e /bin/build-master-status-from-mysql | |
parent | a06a8eff682afb93d86fdebdef336565f26130ee (diff) | |
download | builder-9dc2f0416b3865298a86815d5d18b59a6a50d471.tar.xz |
bin/build-master-status-from-mysql: look at deletion-list, too
Diffstat (limited to 'bin/build-master-status-from-mysql')
-rwxr-xr-x | bin/build-master-status-from-mysql | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/bin/build-master-status-from-mysql b/bin/build-master-status-from-mysql index b56efca..b1bbb98 100755 --- a/bin/build-master-status-from-mysql +++ b/bin/build-master-status-from-mysql @@ -29,6 +29,27 @@ trap 'rm -rf --one-file-system "${tmp_dir}"' EXIT sort "${work_dir}/build-list" > \ "${tmp_dir}/build-list.file" + +# shellcheck disable=SC2016 +{ + printf 'SELECT DISTINCT `package_sources`.`pkgbase`' + printf ' FROM `package_sources`' + printf ' JOIN `%s` ON `%s`.`%s`=`%s`.`id`' \ + 'build_assignments' 'build_assignments' 'package_source' 'package_sources' \ + 'binary_packages' 'binary_packages' 'build_assignment' 'build_assignments' \ + 'repositories' 'binary_packages' 'repository' 'repositories' + printf ' WHERE `repositories`.`name`="deletion-list";\n' +} | \ + ${mysql_command} --batch | \ + sed ' + 1d + y/\t/ / + ' | \ + sort > \ + "${tmp_dir}/deletion-list.mysql" +sort "${work_dir}/deletion-list" > \ + "${tmp_dir}/deletion-list.file" + # shellcheck disable=SC2016 { printf 'SELECT `package_sources`.`pkgbase`' @@ -58,6 +79,10 @@ find "${work_dir}/build-list.loops" -regextype grep -mindepth 1 -maxdepth 1 \ "${tmp_dir}/build-list.mysql" || \ true diff -u \ + "${tmp_dir}/deletion-list.file" \ + "${tmp_dir}/deletion-list.mysql" || \ + true + diff -u \ "${tmp_dir}/loops.file" \ "${tmp_dir}/loops.mysql" || \ true |