summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2017-12-03 21:36:04 +0100
committerErich Eckner <git@eckner.net>2017-12-03 21:36:04 +0100
commit019fdbd77a60d54dceb0cc400a943cc2fc220497 (patch)
tree5729baf061d23dcebbe7b9ff1ba3e1e6fb3410e0 /bin
parentd5196c00bfaacfc83fc4bb7e75b781ea9f8642f2 (diff)
downloadbuilder-019fdbd77a60d54dceb0cc400a943cc2fc220497.tar.xz
bin/interpret-mail: output something if no valid records found, too
Diffstat (limited to 'bin')
-rwxr-xr-xbin/interpret-mail16
1 files changed, 4 insertions, 12 deletions
diff --git a/bin/interpret-mail b/bin/interpret-mail
index 19e2e7b..2b2974f 100755
--- a/bin/interpret-mail
+++ b/bin/interpret-mail
@@ -186,9 +186,7 @@ sed -n "$(
if [ -s "${tmp_dir}/block" ]; then
if run_and_log_on_error "${base_dir}/bin/modify-package-state" --block "${tmp_dir}/block"; then
- if [ -s "${tmp_dir}/block" ]; then
- log 'Successfully blocked %s packages.\n' "$(wc -l < "${tmp_dir}/block")"
- fi
+ log 'Successfully blocked %s packages.\n' "$(wc -l < "${tmp_dir}/block")"
else
log 'There was an error while blocking the packages - ignoring this message.\n'
fi
@@ -199,9 +197,7 @@ if [ -s "${tmp_dir}/stabilize" ]; then
/\.pkg\.tar\.xz$/!s/$/.pkg.tar.xz/
' "${tmp_dir}/stabilize"
if run_and_log_on_error "${base_dir}/bin/modify-package-state" --tested "${tmp_dir}/stabilize"; then
- if [ -s "${tmp_dir}/stabilize" ]; then
- log 'Successfully marked %s packages as tested.\n' "$(wc -l < "${tmp_dir}/stabilize")"
- fi
+ log 'Successfully marked %s packages as tested.\n' "$(wc -l < "${tmp_dir}/stabilize")"
else
log 'There was an error while marking the packages as tested - ignoring this message.\n'
fi
@@ -209,9 +205,7 @@ fi
if [ -s "${tmp_dir}/unblock" ]; then
if run_and_log_on_error "${base_dir}/bin/modify-package-state" --unblock "${tmp_dir}/unblock"; then
- if [ -s "${tmp_dir}/unblock" ]; then
- log 'Successfully unblocked %s packages.\n' "$(wc -l < "${tmp_dir}/unblock")"
- fi
+ log 'Successfully unblocked %s packages.\n' "$(wc -l < "${tmp_dir}/unblock")"
else
log 'There was an error while unblocking the packages - ignoring this message.\n'
fi
@@ -228,7 +222,5 @@ if [ -s "${tmp_dir}/schedule" ]; then
done
) | \
sponge "${tmp_dir}/schedule"
- if [ -s "${tmp_dir}/schedule" ]; then
- log 'Successfully (re)scheduled %s packages.\n' "$(wc -l < "${tmp_dir}/schedule")"
- fi
+ log 'Successfully (re)scheduled %s packages.\n' "$(wc -l < "${tmp_dir}/schedule")"
fi