- Install ganache-cli
- Install GoLang
- Run following to install solidity using asdf
asdf plugin add solidity asdf install solidity 0.7.6
- install cobra and cobra-cli
go get -u github.com/spf13/cobra@latest go install github.com/spf13/cobra-cli@latest
- init cmd structure
CAUTION:
cobra-cli init --viper
cobra-cli init
overrides files (e.g.main.go
,cmd/root.go
)
- Generate interface for DominionApp on Blockchain
cd ./contracts && ./generate.sh && cd ..
- Start a local blockchain with required acc
./ganache-cli.sh
- Use a new terminal to start the demo application
go run main.go demo
...not yet implemented, but will work like this:
- Start a local blockchain with required acc
./ganache-cli.sh
- Use a new terminal to start a cli as alice
go run main.go play --config alice.yml
- Use a new terminal to start a cli as bob
go run main.go play --config bob.yml