Skip to content

Commit

Permalink
Merge pull request #603 from CosmWasm/adjust-publish-order
Browse files Browse the repository at this point in the history
Adjust order of publishing to handle new deps
  • Loading branch information
ethanfrey authored Dec 23, 2021
2 parents 2bc04ec + 919cd5b commit 36449b7
Showing 1 changed file with 19 additions and 3 deletions.
22 changes: 19 additions & 3 deletions scripts/publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,12 @@ STORAGE_PACKAGES="storage-plus"
BASE_PACKAGES="utils"
ALL_PACKAGES="controllers cw1 cw2 cw3 cw4 cw20 cw1155 multi-test"

# This is imported by cw3-fixed-multisig, which is imported by cw3-flex-multisig
# need to make a separate category to remove race conditions
CW20_BASE="cw20-base"
# these are imported by other contracts
BASE_CONTRACTS="cw1-whitelist cw4-group cw20-base"
ALL_CONTRACTS="cw1-subkeys cw3-fixed-multisig cw3-flex-multisig cw4-stake cw20-atomic-swap cw20-bonding cw20-escrow cw20-ics20 cw20-staking cw1155-base"
BASE_CONTRACTS="cw1-whitelist cw4-group cw3-fixed-multisig "
ALL_CONTRACTS="cw1-subkeys cw3-flex-multisig cw4-stake cw20-atomic-swap cw20-bonding cw20-escrow cw20-ics20 cw20-staking cw1155-base"

SLEEP_TIME=30

Expand Down Expand Up @@ -46,10 +49,23 @@ for pack in $ALL_PACKAGES; do
)
done


# wait for these to be processed on crates.io
echo "Waiting for publishing all packages"
sleep $SLEEP_TIME

for cont in CW20_BASE; do
(
cd "contracts/$cont"
echo "Publishing $cont"
cargo publish
)
done

# wait for these to be processed on crates.io
echo "Waiting for publishing cw20 base"
sleep $SLEEP_TIME

for cont in $BASE_CONTRACTS; do
(
cd "contracts/$cont"
Expand All @@ -59,7 +75,7 @@ for cont in $BASE_CONTRACTS; do
done

# wait for these to be processed on crates.io
echo "Waiting for publishing base packages"
echo "Waiting for publishing base contracts"
sleep $SLEEP_TIME

for cont in $ALL_CONTRACTS; do
Expand Down

0 comments on commit 36449b7

Please sign in to comment.