From be861a863a4228d19c2df95ba81de8a891d4643b Mon Sep 17 00:00:00 2001 From: Jake Hartnell Date: Mon, 22 Jul 2024 19:45:58 +0200 Subject: [PATCH] Add new contracts to publishing script. (#853) --- .../cw-fund-distributor/README.md | 10 +++++-- scripts/publish.sh | 29 +++++++++++++++---- 2 files changed, 30 insertions(+), 9 deletions(-) mode change 100644 => 100755 scripts/publish.sh diff --git a/contracts/distribution/cw-fund-distributor/README.md b/contracts/distribution/cw-fund-distributor/README.md index 1df4f15bd..3896499c2 100644 --- a/contracts/distribution/cw-fund-distributor/README.md +++ b/contracts/distribution/cw-fund-distributor/README.md @@ -1,17 +1,21 @@ # cw-fund-distributor -This contract is meant to facilitate fund distribution +This contract is meant to facilitate fund distribution proportional to the amount of voting power members have at a given block height. Possible use cases may involve: + - Dissolving a DAO and distributing its treasury to members prior to shutting down - Distributing funds among DAO members - Funding subDAOs +> **WARNING:** THIS CONTRACT IS NOT AUDITED AND IS _EXPERIMENTAL_. USE AT YOUR +> OWN RISK. + ## Funding Period -Contract is instantiated with a `funding_period` - a time duration that should suffice +Contract is instantiated with a `funding_period` - a time duration that should suffice to move the funds to be distributed into the distributor contract. Funding the contract can only happen during this period. @@ -32,6 +36,6 @@ it is possible to redistribute the unclaimed funds. Only the `cw_admin` can call the method. The redistribution method finds all the claims that have been performed -and subtracts the amounts from the initially funded balance. The respective +and subtracts the amounts from the initially funded balance. The respective allocation ratios for each DAO member remain the same; any previous claims are cleared. diff --git a/scripts/publish.sh b/scripts/publish.sh old mode 100644 new mode 100755 index 9b42ab909..2da542f4c --- a/scripts/publish.sh +++ b/scripts/publish.sh @@ -67,6 +67,8 @@ cd packages/dao-dao-macros cargo hack publish --no-dev-deps --allow-dirty cd "$START_DIR" +sleep 120 + cd packages/dao-voting cargo publish cd "$START_DIR" @@ -77,11 +79,15 @@ cd "$START_DIR" sleep 120 +cd packages/cw-tokenfactory-types +cargo publish +cd "$START_DIR" + cd packages/dao-pre-propose-base cargo publish cd "$START_DIR" -Test contracts +# Test contracts cd contracts/test/dao-proposal-sudo cargo publish cd "$START_DIR" @@ -187,25 +193,36 @@ cd contracts/voting/dao-voting-token-staked cargo hack publish --no-dev-deps --allow-dirty cd "$START_DIR" -cd contracts/dao-dao-core +cd contracts/voting/dao-voting-onft-staked cargo hack publish --no-dev-deps --allow-dirty cd "$START_DIR" -cd contracts/external/cw-admin-factory +cd contracts/dao-dao-core cargo hack publish --no-dev-deps --allow-dirty cd "$START_DIR" sleep 120 -# TODO re-enable when ready -# cd contracts/external/cw-fund-distributor +cd contracts/external/cw-admin-factory +cargo hack publish --no-dev-deps --allow-dirty +cd "$START_DIR" + +# TODO: uncomment once cleaned up and audited +# cd contracts/distribution/cw-fund-distributor # cargo hack publish --no-dev-deps --allow-dirty # cd "$START_DIR" -cd contracts/external/dao-migrator +cd contracts/distribution/dao-rewards-distributor cargo hack publish --no-dev-deps --allow-dirty cd "$START_DIR" +cd contracts/external/btsg-ft-factory +cargo hack publish --no-dev-deps --allow-dirty +cd "$START_DIR" + +cd contracts/external/dao-migrator +cargo hack publish --no-dev-deps --allow-dirty +cd "$START_DIR" cd packages/dao-testing cargo publish