MCPcopy Create free account
hub / github.com/akash-network/node / initRootCmd

Function initRootCmd

cmd/akash/cmd/root.go:61–91  ·  view source on GitHub ↗
(rootCmd *cobra.Command, encodingConfig sdkutil.EncodingConfig)

Source from the content-addressed store, hash-verified

59}
60
61func initRootCmd(rootCmd *cobra.Command, encodingConfig sdkutil.EncodingConfig) {
62 ac := appCreator{encodingConfig}
63
64 home := app.DefaultHome
65
66 debugCmd := debug.Cmd()
67 debugCmd.AddCommand(ConvertBech32Cmd())
68
69 rootCmd.AddCommand(
70 sdkserver.StatusCommand(),
71 AuthCmd(),
72 cli.EventsCmd(),
73 cli.QueryCmd(),
74 cli.TxCmd(),
75 cli.KeysCmds(),
76 genesisCommand(encodingConfig),
77 cmtcli.NewCompletionCmd(rootCmd, true),
78 debugCmd,
79 rosettaCmd.RosettaCommand(encodingConfig.InterfaceRegistry, encodingConfig.Codec),
80 pruning.Cmd(ac.newApp, home),
81 snapshot.Cmd(ac.newApp),
82 testnetCmd(app.ModuleBasics(), banktypes.GenesisBalancesIterator{}),
83 PrepareGenesisCmd(app.DefaultHome, app.ModuleBasics()),
84 testnetify.GetCmd(ac.newTestnetApp),
85 )
86
87 cli.ServerCmds(rootCmd, home, ac.newApp, ac.appExport, addModuleInitFlags)
88
89 rootCmd.SetOut(rootCmd.OutOrStdout())
90 rootCmd.SetErr(rootCmd.ErrOrStderr())
91}
92
93func addModuleInitFlags(startCmd *cobra.Command) {
94 crisis.AddModuleInitFlags(startCmd) //nolint: staticcheck

Callers 1

NewRootCmdFunction · 0.85

Calls 7

ModuleBasicsFunction · 0.92
GetCmdFunction · 0.92
ConvertBech32CmdFunction · 0.85
AuthCmdFunction · 0.85
genesisCommandFunction · 0.85
testnetCmdFunction · 0.85
PrepareGenesisCmdFunction · 0.85

Tested by

no test coverage detected