diff options
author | Erich Eckner <git@eckner.net> | 2018-02-01 15:24:31 +0100 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2018-02-01 15:24:31 +0100 |
commit | 8873150c610b1a5e7053cd1a462561b72cb6785e (patch) | |
tree | d50e5cfa3a2f77717d05023e5a2b227e624bd976 /bin | |
parent | e46909f8589a0dadffafbe1f59997be3252afb5f (diff) | |
download | builder-8873150c610b1a5e7053cd1a462561b72cb6785e.tar.xz |
bin/build-master-status-from-mysql: check tesing packages, too
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/build-master-status-from-mysql | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/bin/build-master-status-from-mysql b/bin/build-master-status-from-mysql index 16353dd..8e828f7 100755 --- a/bin/build-master-status-from-mysql +++ b/bin/build-master-status-from-mysql @@ -110,6 +110,42 @@ find "${work_dir}/package-states" -mindepth 1 -maxdepth 1 \ sort -u > \ "${tmp_dir}/tested.file" +# shellcheck disable=SC2016 +{ + printf 'SELECT ' + printf '`binary_packages`.`%s`,' \ + 'pkgname' \ + 'epoch' \ + 'pkgver' \ + 'pkgrel' \ + 'sub_pkgrel' + printf '`architectures`.`name`' + printf ' FROM `binary_packages`' + printf ' JOIN `%s` ON `%s`.`id`=`%s`.`%s`' \ + 'repositories' 'repositories' 'binary_packages' 'repository' \ + 'architectures' 'architectures' 'binary_packages' 'architecture' \ + 'repository_stabilities' 'repository_stabilities' 'repositories' 'stability' + printf ' WHERE NOT `binary_packages`.`is_tested`' + printf ' AND NOT `binary_packages`.`has_issues`' + printf ' AND `repository_stabilities`.`name`="testing"' +} | \ + ${mysql_command} --batch | \ + sed ' + 1d + s/^\(\S\+\)\s\(\S\+\)\s\(\S\+\)\s\(\S\+\)\s\(\S\+\)\s\(\S\+\)$/\1-\2:\3-\4.\5-\6.pkg.tar.xz/ + ' | \ + sort -u > \ + "${tmp_dir}/testing.mysql" +find "${work_dir}/package-states" -mindepth 1 -maxdepth 1 \ + -name '*.testing' \ + -exec cat '{}' \; | \ + sed ' + s/-\([^-.]\+\)\(-[^-]\+\)$/-\1.0-\2/ + s/-\([^-:]\+\)\(\(-[^-]\+\)\{2\}\)$/-0:\1\2/ + ' | \ + sort -u > \ + "${tmp_dir}/testing.file" + { mysql_sanity_check || true diff -u \ @@ -128,6 +164,10 @@ find "${work_dir}/package-states" -mindepth 1 -maxdepth 1 \ "${tmp_dir}/tested.file" \ "${tmp_dir}/tested.mysql" || \ true + diff -u \ + "${tmp_dir}/testing.file" \ + "${tmp_dir}/testing.mysql" || \ + true } | \ sed ' s,^-.*$,<font color="#FF0000">\0</font>, |