init initializes the root command and sets up flags
()
| 34 | |
| 35 | // init initializes the root command and sets up flags |
| 36 | func init() { |
| 37 | // Add persistent flags |
| 38 | addPersistentFlags(RootCmd) |
| 39 | |
| 40 | // Add commands |
| 41 | RootCmd.AddCommand(newConfigWizardCmd()) |
| 42 | RootCmd.AddCommand(newNodesCmd()) |
| 43 | RootCmd.AddCommand(newGuestsCmd()) |
| 44 | RootCmd.AddCommand(newTasksCmd()) |
| 45 | RootCmd.AddCommand(newStorageCmd()) |
| 46 | RootCmd.AddCommand(newCommunityScriptsCmd()) |
| 47 | |
| 48 | // Output format flag (inherited by all subcommands) |
| 49 | RootCmd.PersistentFlags().StringP("output", "o", outputJSON, "Output format: json, table") |
| 50 | } |
| 51 | |
| 52 | // runMainApplication runs the main application |
| 53 | func runMainApplication(cmd *cobra.Command, args []string) error { |
nothing calls this directly
no test coverage detected