From: Dave Wallace Date: Thu, 22 Jul 2021 18:54:11 +0000 (-0400) Subject: Fix: Don't exit on error while collecting data for _sys-info.log X-Git-Tag: v0.35.4^0 X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F15%2F68315%2F2;p=releng%2Flftools.git Fix: Don't exit on error while collecting data for _sys-info.log Change-Id: Ic3ed23b727b4663f01e52205641b23505518d3b9 Signed-off-by: Dave Wallace --- diff --git a/shell/deploy b/shell/deploy index f401bc6d..9e825947 100755 --- a/shell/deploy +++ b/shell/deploy @@ -229,6 +229,8 @@ deploy_logs() { env | grep -v -E "COOKIE|DOCKER|HUDSON|KEY|PASSWORD|SSH|TOKEN" | sort > "_build-enviroment-variables.log" # Print system info before collecting logs + local set_opts="$-" + set +e # disable exit on errors touch "_sys-info.log" { local sys_cmds @@ -251,6 +253,7 @@ deploy_logs() { fi done } 2>&1 | tee -a "_sys-info.log" + grep -q e <<< "$set_opts" && set -e # re-enable exit on errors # Magic string used to trim console logs at the appropriate level during wget MAGIC_STRING="-----END_OF_BUILD-----"