-
Golanghttps://go.dev/dl/ -
Solidityhttps://docs.soliditylang.org/en/v0.8.2/installing-solidity.html Version: 0.8.20 -
Solidity compiler (solc)https://docs.soliditylang.org/en/latest/installing-solidity.html
Version: 0.8.25-develop -
Ganache-clihttps://www.npmjs.com/package/ganache-cli -
AbigenVersion: v1.14.3go get -u github.com/ethereum/go-ethereum go install github.com/ethereum/go-ethereum/cmd/abigen@v1.14.3
-
main.gorun this file to test the functionalities of the framework. -
incentive.gorun this file to test the incentive mechanism. -
compile/contract/The folder stores contract source code file (.sol) and generated go contract file. -
compile/compile.shThe script file compiles solidity and generates go contract file. -
genPrvKey.shThe script file generates accounts and stores in the.envfile.
-
Generate private keys to generate the
.envfilebash genPrvKey.sh
-
start ganache
ganache --mnemonic "dttp" -l 90071992547 -e 1000 -
Compile the smart contract code
bash compile.sh
-
Run the main.go
go run main.go