Skip to content

Commit 7ed6aec

Browse files
Merge pull request #360 from appdevforall/fix/rootfs-builder-set-e-set-tag
fix(rootfs-builder): _set_tag returned 1 under set -e, aborting every build
2 parents 58013cc + f05a65a commit 7ed6aec

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎tools/rootfs-builder/build-iiab-rootfs.sh‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ RED="\033[31m"; YEL="\033[33m"; GRN="\033[32m"; BLU="\033[34m"; RST="\033[0m"; B
8787
# BUILD_TAG is computed once (children inherit a fixed BUILD_PROGRESS; the parent re-runs _set_tag per
8888
# combo) so the log helpers don't fork a subshell per line.
8989
BUILD_TAG=""
90-
_set_tag() { BUILD_TAG=""; [[ -n "${BUILD_PROGRESS:-}" ]] && BUILD_TAG="(${BUILD_PROGRESS})"; }
90+
_set_tag() { BUILD_TAG=""; [[ -n "${BUILD_PROGRESS:-}" ]] && BUILD_TAG="(${BUILD_PROGRESS})"; return 0; } # return 0: never let the && list make this fn return 1 under set -e
9191
_set_tag # pick up an inherited BUILD_PROGRESS (this is a child build spawned by the parent)
9292
ok() { printf "${GRN}[build]${BUILD_TAG}${RST} %s\n" "$*"; }
9393
log() { printf "${BLU}[build]${BUILD_TAG}${RST} %s\n" "$*"; }

0 commit comments

Comments
 (0)