summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2017-07-27 08:40:27 +0200
committerErich Eckner <git@eckner.net>2017-07-27 08:40:27 +0200
commitb9e8973df4657278873472b13a28de285f43e33a (patch)
tree1103edc79b6e7e9c90f40409e32dcb89db87c857 /bin
parente2d038d4aaa8f0ce171ff5050b5a709813283a6b (diff)
downloadbuilder-b9e8973df4657278873472b13a28de285f43e33a.tar.xz
bin/build-packages: remove bug which prevents tmpdirs from being deleted in some cases
Diffstat (limited to 'bin')
-rwxr-xr-xbin/build-packages24
1 files changed, 12 insertions, 12 deletions
diff --git a/bin/build-packages b/bin/build-packages
index c0c5266..da96838 100755
--- a/bin/build-packages
+++ b/bin/build-packages
@@ -213,7 +213,7 @@ while [ ${count} -ne 0 ]; do
rm -f *".pkg.tar.xz" *".pkg.tar.xz.sig"
- >&2 printf 'building package "%s" ...' "${package}"
+ >&2 printf 'building package "%s" (straw: %s) ...' "${package}" "${straw}"
# by piping the log, we don't see anything in the terminal,
# but all ways to duplicate the logs seem pretty elaborate
if "${build_command}" ${parameters} > \
@@ -277,17 +277,17 @@ while [ ${count} -ne 0 ]; do
gzip "${log}"
fi
done
- tar -cf 'build-logs.gz.tar' \
- *'.build-log.gz' || \
- continue # this might happen if we didn't create any logs
- while ! ssh \
- -i "${master_build_server_identity}" \
- -p "${master_build_server_port}" \
- "${master_build_server_user}@${master_build_server}" \
- 'return-assignment' "${package}" "${git_revision}" "${mod_git_revision}" "${repository}" 'ERROR' < \
- 'build-logs.gz.tar'; do
- wait_some_time 15
- done
+ if tar -cf 'build-logs.gz.tar' \
+ *'.build-log.gz'; then
+ while ! ssh \
+ -i "${master_build_server_identity}" \
+ -p "${master_build_server_port}" \
+ "${master_build_server_user}@${master_build_server}" \
+ 'return-assignment' "${package}" "${git_revision}" "${mod_git_revision}" "${repository}" 'ERROR' < \
+ 'build-logs.gz.tar'; do
+ wait_some_time 15
+ done
+ fi
if ${exit_after_failure}; then
>&2 echo 'Build failed, exiting now'
bail_out 0