Skip to content

Commit

Permalink
chore(cosmos): Add CLI missing commands
Browse files Browse the repository at this point in the history
  • Loading branch information
mhofman committed Feb 23, 2024
1 parent 6adf238 commit c27b24e
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions golang/cosmos/daemon/cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ import (
"github.com/cosmos/cosmos-sdk/client/debug"
"github.com/cosmos/cosmos-sdk/client/flags"
"github.com/cosmos/cosmos-sdk/client/keys"
"github.com/cosmos/cosmos-sdk/client/pruning"
"github.com/cosmos/cosmos-sdk/client/rpc"
"github.com/cosmos/cosmos-sdk/client/snapshot"
"github.com/cosmos/cosmos-sdk/server"
servertypes "github.com/cosmos/cosmos-sdk/server/types"
"github.com/cosmos/cosmos-sdk/snapshots"
Expand Down Expand Up @@ -126,22 +128,26 @@ func initRootCmd(sender Sender, rootCmd *cobra.Command, encodingConfig params.En
cfg := sdk.GetConfig()
cfg.Seal()

ac := appCreator{
encCfg: encodingConfig,
sender: sender,
}

rootCmd.AddCommand(
genutilcli.InitCmd(gaia.ModuleBasics, gaia.DefaultNodeHome),
genutilcli.CollectGenTxsCmd(banktypes.GenesisBalancesIterator{}, gaia.DefaultNodeHome),
genutilcli.MigrateGenesisCmd(),
genutilcli.GenTxCmd(gaia.ModuleBasics, encodingConfig.TxConfig, banktypes.GenesisBalancesIterator{}, gaia.DefaultNodeHome),
genutilcli.ValidateGenesisCmd(gaia.ModuleBasics),
AddGenesisAccountCmd(encodingConfig.Marshaler, gaia.DefaultNodeHome),
tmcli.NewCompletionCmd(rootCmd, true),
testnetCmd(gaia.ModuleBasics, banktypes.GenesisBalancesIterator{}),
debug.Cmd(),
config.Cmd(),
pruning.Cmd(ac.newApp, gaia.DefaultNodeHome),
snapshot.Cmd(ac.newApp),
)

ac := appCreator{
encCfg: encodingConfig,
sender: sender,
}
server.AddCommands(rootCmd, gaia.DefaultNodeHome, ac.newApp, ac.appExport, addModuleInitFlags)

for _, command := range rootCmd.Commands() {
Expand Down Expand Up @@ -231,6 +237,7 @@ func txCommand() *cobra.Command {
authcmd.GetBroadcastCommand(),
authcmd.GetEncodeCommand(),
authcmd.GetDecodeCommand(),
authcmd.GetAuxToFeeCommand(),
flags.LineBreak,
vestingcli.GetTxCmd(),
)
Expand Down

0 comments on commit c27b24e

Please sign in to comment.