Setup genesis whenever contracts get changed
$ npm install
$ git submodule init
$ git submodule update$ cd matic-contracts
$ npm install
$ node scripts/process-templates.js --bor-chain-id <bor-chain-id>
$ npm run truffle:compile
$ cd ..Following command will generate BorValidatorSet.sol file from BorValidatorSet.template file.
# Generate bor validator set using stake and balance
# Modify validators.json before as per your need
$ node generate-borvalidatorset.js --bor-chain-id <bor-chain-id> --heimdall-chain-id <heimdall-chain-id>$ npm run truffle:compileTo add custom block time and associated block no.s in genesis, edit the blocks.js file
Following command will generate genesis.json file from genesis-template.json file.
# Generate genesis file
$ node generate-genesis.js --bor-chain-id <bor-chain-id> --heimdall-chain-id <heimdall-chain-id>$ npm run testrpc
$ npm test