Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/bin/why-dont-you
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2020-02-14 10:58:22 +0100
committerErich Eckner <git@eckner.net>2020-02-14 10:58:22 +0100
commit19d293888b4746f130e451c2c947ce715da4abba (patch)
treeaf47d1aff09a6eecf8f8dc7b2007247ae79d6571 /bin/why-dont-you
parentcd15864dbda079227f5c5d674ca7fedbcbc80057 (diff)
bin/why-dont-you: show search term in case of not-found package
Diffstat (limited to 'bin/why-dont-you')
-rwxr-xr-xbin/why-dont-you14
1 files changed, 10 insertions, 4 deletions
diff --git a/bin/why-dont-you b/bin/why-dont-you
index a052fff..1f4916b 100755
--- a/bin/why-dont-you
+++ b/bin/why-dont-you
@@ -34,6 +34,7 @@ case "${action}" in
) | \
sed 's/,$/;\n/'
# we select everything which is possibly of any interest:
+ # - search term
# - id (to see if it actually is on the build-list)
# - build_assignments.architecture.name
# - to_build.is_broken
@@ -42,7 +43,8 @@ case "${action}" in
# - deps.pkgbase (any dependency pending?)
# - build_slaves.name (is anyone building this?)
# - pkgbase
- printf 'SELECT DISTINCT `to_build`.`ba_id`,'
+ printf 'SELECT DISTINCT replace(to_base64(`searches`.`search`),"\\n","")'
+ printf '`to_build`.`ba_id`,'
printf '`to_build`.`baa_name`,'
printf 'If(`to_build`.`is_broken`,1,0),'
printf '('
@@ -105,7 +107,7 @@ case "${action}" in
} | \
mysql_run_query 'unimportant' | \
tr '\t' ' ' | \
- sort -k8,8 -k7,7 -k6,6 | \
+ sort -k9,9 -k8,8 -k7,7 | \
sed '
/ NULL \S\+$/ b multi-dep
:multi-slave
@@ -125,14 +127,18 @@ case "${action}" in
sed '
s/NULL,//g
' | \
- while read -r id ba_arch is_broken trials is_blocked dependency slave pkgbase; do
+ while read -r search id ba_arch is_broken trials is_blocked dependency slave pkgbase; do
+ search=$(
+ printf '%s' "${search}" | \
+ base64 -d
+ )
pkgbase=$(
printf '%s' "${pkgbase}" | \
base64 -d
)
if [ "${id}" = 'NULL' ]; then
>&2 printf '"%s" is not on the build list.\n' \
- "${pkgbase}"
+ "${search}"
continue
fi
if [ "${slave}" != 'NULL' ]; then