Setup genesis whenever contracts get changed
$ npm install
$ git submodule init
$ git submodule update
$ cd bttc-contracts
$ npm install
$ node scripts/process-templates.js --bttc-chain-id <bttc-chain-id>
$ npm run truffle:compile
$ cd ..
Following command will generate BorValidatorSet.sol
file from BorValidatorSet.template
file.
# Generate bttc validator set using stake and balance
# Modify validators.json before as per your need
$ node generate-borvalidatorset.js --bttc-chain-id <bttc-chain-id> --delivery-chain-id <delivery-chain-id>
$ npm run truffle:compile
Following command will generate genesis.json
file from genesis-template.json
file.
# Generate genesis file
$ node generate-genesis.js --bttc-chain-id <bttc-chain-id> --delivery-chain-id <delivery-chain-id>
$ npm run testrpc
$ npm test