Skip to content

Commit b27fc7d

Browse files
authored
Add pruning command (CosmosContracts#319)
1 parent 97f3c21 commit b27fc7d

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

cmd/junod/root.go

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import (
1212
"github.com/cosmos/cosmos-sdk/client/debug"
1313
"github.com/cosmos/cosmos-sdk/client/flags"
1414
"github.com/cosmos/cosmos-sdk/client/keys"
15+
"github.com/cosmos/cosmos-sdk/client/pruning"
1516
"github.com/cosmos/cosmos-sdk/client/rpc"
1617
"github.com/cosmos/cosmos-sdk/server"
1718
servertypes "github.com/cosmos/cosmos-sdk/server/types"
@@ -93,6 +94,10 @@ func NewRootCmd() (*cobra.Command, params.EncodingConfig) {
9394
}
9495

9596
func initRootCmd(rootCmd *cobra.Command, encodingConfig params.EncodingConfig) {
97+
ac := appCreator{
98+
encCfg: encodingConfig,
99+
}
100+
96101
rootCmd.AddCommand(
97102
genutilcli.InitCmd(app.ModuleBasics, app.DefaultNodeHome),
98103
genutilcli.CollectGenTxsCmd(banktypes.GenesisBalancesIterator{}, app.DefaultNodeHome),
@@ -105,11 +110,9 @@ func initRootCmd(rootCmd *cobra.Command, encodingConfig params.EncodingConfig) {
105110
// testnetCmd(app.ModuleBasics, banktypes.GenesisBalancesIterator{}),
106111
debug.Cmd(),
107112
config.Cmd(),
113+
pruning.PruningCmd(ac.newApp),
108114
)
109115

110-
ac := appCreator{
111-
encCfg: encodingConfig,
112-
}
113116
server.AddCommands(rootCmd, app.DefaultNodeHome, ac.newApp, ac.appExport, addModuleInitFlags)
114117

115118
// add keybase, auxiliary RPC, query, and tx child commands

0 commit comments

Comments
 (0)