Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix setting ARGS in the factory README #181

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions sputnikdao-factory2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ set CONTRACT_ID "dev-1608694678554-8567049"
near call $CONTRACT_ID new '{}' --accountId $CONTRACT_ID

# bash
ARGS=`echo '{"purpose": "test", "council": ["testmewell.testnet", "illia"], "bond": "1000000000000000000000000", "vote_period": "1800000000000", "grace_period": "1800000000000"}' | base64`

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here we can decide about bond value, voting period and grace_period but after modifications we can't.

How we could improve ARGS to define them ?

ARGS=`echo '{"config": {"name": "test", "purpose": "test", "metadata": ""}, "policy": ["'$CONTRACT_ID'"]}' | base64`
# fish
set ARGS (echo '{"purpose": "test", "council": ["testmewell.testnet", "illia"], "bond": "1000000000000000000000000", "vote_period": "1800000000000", "grace_period": "1800000000000"}' | base64)
set ARGS (echo '{"config": {"name": "test", "purpose": "test", "metadata": ""}, "policy": ["'$CONTRACT_ID'"]}' | base64)

# Create a new DAO with the given parameters.
near call $CONTRACT_ID create "{\"name\": \"test\", \"public_key\": null, \"args\": \"$ARGS\"}" --accountId $CONTRACT_ID --amount 30 --gas 100000000000000
Expand Down Expand Up @@ -73,4 +73,4 @@ V1 is archived in a different repo. :)
"create"
],
}
```
```