Skip to content

Commit

Permalink
add snapshot and pruning cmds
Browse files Browse the repository at this point in the history
  • Loading branch information
harish551 committed Aug 26, 2024
1 parent 8de3e18 commit 6b42a45
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions cmd/omniflixhubd/cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ import (
"github.com/cosmos/cosmos-sdk/client"
"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"
runtimeservices "github.com/cosmos/cosmos-sdk/runtime/services"
"github.com/cosmos/cosmos-sdk/server"
servertypes "github.com/cosmos/cosmos-sdk/server/types"
Expand Down Expand Up @@ -130,6 +132,9 @@ func initCometBftConfig() *tmcfg.Config {
}

func initRootCmd(rootCmd *cobra.Command, encodingConfig params.EncodingConfig, tempApp *app.OmniFlixApp) {
ac := appCreator{
encCfg: encodingConfig,
}
rootCmd.AddCommand(
genutilcli.InitCmd(tempApp.ModuleBasics, app.DefaultNodeHome),
tmcli.NewCompletionCmd(rootCmd, true),
Expand All @@ -150,12 +155,10 @@ func initRootCmd(rootCmd *cobra.Command, encodingConfig params.EncodingConfig, t
genutilcli.ValidateGenesisCmd(tempApp.ModuleBasics),
tmcli.NewCompletionCmd(rootCmd, true),
addDebugCommands(debug.Cmd()),
pruning.Cmd(ac.newApp, app.DefaultNodeHome),
snapshot.Cmd(ac.newApp),
)

ac := appCreator{
encCfg: encodingConfig,
}

server.AddCommands(rootCmd, app.DefaultNodeHome, ac.newApp, ac.appExport, addModuleInitFlags)

// add keybase, auxiliary RPC, query, and tx child commands
Expand Down

0 comments on commit 6b42a45

Please sign in to comment.