Skip to content
This repository has been archived by the owner on Dec 18, 2024. It is now read-only.

Commit

Permalink
Remove array expansion
Browse files Browse the repository at this point in the history
  • Loading branch information
khssnv committed Nov 6, 2023
1 parent 0025b96 commit 8de41e0
Showing 1 changed file with 6 additions and 10 deletions.
16 changes: 6 additions & 10 deletions zombienet.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,6 @@
ZOMBIENET_V=v1.3.68
POLKADOT_V=v1.1.0

POLKADOT_FILES=(
"polkadot"
"polkadot-execute-worker"
"polkadot-prepare-worker"
)

case "$(uname -s)" in
Linux*) MACHINE=Linux;;
Darwin*) MACHINE=Mac;;
Expand All @@ -31,7 +25,9 @@ build_polkadot(){
git checkout polkadot-$POLKADOT_V
echo "building polkadot executable..."
cargo build --release --features fast-runtime
cp "${POLKADOT_FILES[@]/#/target/release/}" "$CWD/bin"
cp target/release/polkadot "$CWD/bin"
cp target/release/polkadot-execute-worker "$CWD/bin"
cp target/release/polkadot-prepare-worker "$CWD/bin"
popd
popd
}
Expand All @@ -42,9 +38,9 @@ zombienet_init() {
curl -LO https://github.com/paritytech/zombienet/releases/download/$ZOMBIENET_V/$ZOMBIENET_BIN
chmod +x $ZOMBIENET_BIN
fi
for file in "${POLKADOT_FILES[@]}"; do
[[ -f "bin/$file" ]] || { build_polkadot; break; }
done
if [ ! -f bin/polkadot ] || [ ! -f bin/polkadot-execute-worker ] || [ ! -f bin/polkadot-prepare-worker ]; then
build_polkadot
fi
}

zombienet_spawn() {
Expand Down

0 comments on commit 8de41e0

Please sign in to comment.