Documentation ¶
Index ¶
- func GenerateCoinKey() (crypto.Address, string, error)
- func GetGenesisJSON(pubkey, chainID, denom, addr string, options string) string
- func InitCmd(gen GenOptions, logger log.Logger) *cobra.Command
- func StartCmd(app appGenerator, logger log.Logger) *cobra.Command
- func UnsafeResetAllCmd(logger log.Logger) *cobra.Command
- type GenOptions
- type GenesisDoc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateCoinKey ¶
GenerateCoinKey returns the address of a public key, along with the secret phrase to recover the private key. You can give coins to this address and return the recovery phrase to the user to access them.
func GetGenesisJSON ¶ added in v0.11.0
GetGenesisJSON returns a new tendermint genesis with Basecoin app_options that grant a large amount of "mycoin" to a single address TODO: A better UX for generating genesis files
func InitCmd ¶
func InitCmd(gen GenOptions, logger log.Logger) *cobra.Command
InitCmd will initialize all files for tendermint, along with proper app_options. The application can pass in a function to generate proper options. And may want to use GenerateCoinKey to create default account(s).
Types ¶
type GenOptions ¶ added in v0.11.0
type GenOptions func(args []string) (json.RawMessage, error)
GenOptions can parse command-line and flag to generate default app_options for the genesis file. This is application-specific
type GenesisDoc ¶
type GenesisDoc map[string]json.RawMessage
GenesisDoc involves some tendermint-specific structures we don't want to parse, so we just grab it into a raw object format, so we can add one line.