Add env variable to cmd flags (#9040)
* first draft * add tests in config_test package * refactored, all tests pass, r4r * ready for review * add envPrefix * Update simapp/simd/cmd/root.go Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com> * fix linter issues * minor fixes Co-authored-by: Alessio Treglia <alessio@tendermint.com> Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
This commit is contained in:
co-authored by
Amaury
Alessio Treglia
mergify[bot]
parent
cf7b03efcd
commit
a465ae182c
@@ -47,7 +47,7 @@ func NewRootCmd() (*cobra.Command, params.EncodingConfig) {
|
||||
WithAccountRetriever(types.AccountRetriever{}).
|
||||
WithBroadcastMode(flags.BroadcastBlock).
|
||||
WithHomeDir(simapp.DefaultNodeHome).
|
||||
WithViper()
|
||||
WithViper("") // In simapp, we don't use any prefix for env variables.
|
||||
|
||||
rootCmd := &cobra.Command{
|
||||
Use: "simd",
|
||||
|
||||
Reference in New Issue
Block a user