Skip to content

Genesis options flag for init #241

@rigelrozanski

Description

@rigelrozanski

provide a flag --module-options on init to interface with the InitState function which satisfies the Middleware interface. (https://github.com/cosmos/cosmos-sdk/blob/develop/modules/coin/handler.go#L84)

Currently the only way to change genesis options is through manually baked in app options in the genesis file (https://github.com/cosmos/cosmos-sdk/blob/develop/cmd/basecoin/commands/init.go#L117). By adding a flag which has the capability to to initialize a genesis middleware param we eliminate the need for many apps to require their own init.go file with custom genesis creation.

Open to suggestions as to the best format for multiple options to be passed in, so far I was thinking something that might look like:

basecoin init --module-options=<name1>/<optionkey>/<value>,<name2>/<optionkey>/<value>

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions