summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbin/nit-picker51
1 files changed, 51 insertions, 0 deletions
diff --git a/bin/nit-picker b/bin/nit-picker
index 1c87a9c..e073439 100755
--- a/bin/nit-picker
+++ b/bin/nit-picker
@@ -168,6 +168,15 @@ while pgrep -x ii >/dev/null \
printf '`build_slaves`.`name`'
printf ' FROM `build_slaves`'
printf ';\n'
+
+ printf 'SELECT DISTINCT'
+ printf ' "package-blob",'
+ printf '`binary_packages`.`build_assignment`,'
+ printf '`repositories`.`architecture`'
+ printf ' FROM `binary_packages`'
+ mysql_join_binary_packages_binary_packages_in_repositories
+ mysql_join_binary_packages_in_repositories_repositories
+ printf ' AND `repositories`.`is_on_master_mirror`;\n'
fi
fi
@@ -505,6 +514,48 @@ while pgrep -x ii >/dev/null \
rm "${tmp_dir}/${parameters}"
rm -rf --one-file-system "${tmp_dir}/gpg-home" "${tmp_dir}/pkg"
;;
+ 'package-blob')
+ infos=$(
+ # shellcheck disable=SC2016
+ {
+ printf 'SELECT DISTINCT'
+ printf ' CONCAT('
+ printf '`architectures`.`name`,'
+ printf '"/",'
+ printf '`package_sources`.`pkgbase`'
+ printf '),'
+ printf '`repository_stabilities`.`name`'
+ printf ' FROM `binary_packages`'
+ mysql_join_binary_packages_build_assignments
+ printf ' AND `build_assignments`.`id`=%s' \
+ "${parameters% *}"
+ mysql_join_build_assignments_package_sources
+ mysql_join_binary_packages_binary_packages_in_repositories
+ mysql_join_binary_packages_in_repositories_repositories
+ printf ' AND `repositories`.`is_on_master_mirror`'
+ printf ' AND `repositories`.`architecture`=%s' \
+ "${parameters#* }"
+ mysql_join_repositories_repository_stabilities
+ mysql_join_repositories_architectures
+ printf ';\n'
+ } \
+ | mysql_run_query \
+ | tr '\t' ' '
+ )
+ # 0 is ok, too - then the package was removed in the meantime
+ if [ "$(printf '%s\n' "${infos}" | wc -l)" -gt 1 ]; then
+ printf '%s\n' \
+ "${infos}" \
+ | sed '
+ :a
+ $! N
+ s/\n\S\+ /, /
+ ta
+ s/^\S\+ /parts of \0are in differently-stable repositories: /
+ ' \
+ | local_irc_say
+ fi
+ ;;
*)
>&2 printf 'action "%s" is not yet implemented ...\n' "${action}"
;;