Skip to content

Commit 31e25ea

Browse files
committed
chore: add comment to explain double 'tar' command when expanding Cardano archives
1 parent 0684059 commit 31e25ea

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

mithril-test-lab/mithril-devnet/mkfiles/mkfiles-init.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ if [[ "$SKIP_CARDANO_BIN_DOWNLOAD" != "true" ]]; then
7171
echo ">> Downloading cardano-cli & cardano-node..."
7272
curl -sL "${CARDANO_BINARY_URL}" --output cardano-bin.tar.gz
7373
echo ">> Extracting cardano-cli & cardano-node..."
74+
# First tar when archive has a 'bin' directory, and second tar is to handle legacy archive without 'bin' directory
7475
tar xzf cardano-bin.tar.gz -C "${ARTIFACTS_DIR}/" ./bin || (mkdir -p "${ARTIFACTS_DIR}/bin" && tar --strip-components=1 -C "${ARTIFACTS_DIR}/bin" -xzf cardano-bin.tar.gz)
7576
rm -f cardano-bin.tar.gz
7677
fi

0 commit comments

Comments
 (0)