MCPcopy Create free account
hub / github.com/CPChain/chain / DeployNetwork

Function DeployNetwork

tools/smartcontract/deploy/deploy_network.go:28–39  ·  view source on GitHub ↗
(password string, nonce uint64)

Source from the content-addressed store, hash-verified

26)
27
28func DeployNetwork(password string, nonce uint64) common.Address {
29 client, err, privateKey, _, fromAddress := config.Connect(password)
30 printBalance(client, fromAddress)
31 // Launch contract deploy transaction.
32 auth := newTransactor(privateKey, new(big.Int).SetUint64(nonce))
33 contractAddress, tx, _, err := network.DeployNetwork(auth, client)
34 if err != nil {
35 log.Fatal(err.Error())
36 }
37 printTx(tx, err, client, contractAddress)
38 return contractAddress
39}

Callers

nothing calls this directly

Calls 5

newTransactorFunction · 0.85
printTxFunction · 0.85
printBalanceFunction · 0.70
FatalMethod · 0.65
ErrorMethod · 0.65

Tested by

no test coverage detected