Skip to content

Commit a6caff3

Browse files
committed
Fixed unpack-tarballs handling of masterfiles tarballs
The symlink step was failing due to the tarball itself matching the glob Ticket: none Changelog: none (cherry picked from commit f3c42b2)
1 parent d704c10 commit a6caff3

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

‎build-scripts/unpack-tarballs‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,11 @@ cd "$BASEDIR"
6262
gzip -dc $SOURCE_TARBALL | tar -xf -
6363
ln -s cfengine-3* core
6464

65-
log_debug "UNPACKING MASTERFILES TARBALL AND SYMLINKING masterfiles/"
65+
log_debug "UNPACKING MASTERFILES TARBALL: $MASTERFILES_TARBALL AND SYMLINKING masterfiles/"
6666
# shellcheck disable=SC2086
6767
# > Double quote to prevent globbing and word splitting.
6868
# We want globbing here
6969
gzip -dc $MASTERFILES_TARBALL | tar -xf -
70-
ln -s cfengine-masterfiles-* masterfiles
70+
# the masterfiles tarball would match cfengine-masterfiles-* so find the unpacked dir specifically
71+
_cfmpfdir=$(find -type d -name 'cfengine-masterfiles-*')
72+
ln -s "$_cfmpfdir" masterfiles

0 commit comments

Comments
 (0)