Skip to content

Extension framework - consider abstracting away rootCmd #5766

Description

@JeffreyCA
rootCmd := &cobra.Command{
	Use:           "agent <command> [options]",
	Short:         "Placeholder description",
	SilenceUsage:  true,
	SilenceErrors: true,
	CompletionOptions: cobra.CompletionOptions{
		DisableDefaultCmd: true,
	},
}

rootCmd.SetHelpCommand(&cobra.Command{Hidden: true})
rootCmd.PersistentFlags().Bool("debug", false, "Enable debug mode")

nit. If this is expected by AZD for compatible extensions, I would have the azd-client to expose a method to get the rootCmd() with the azd-standards for extensions.

Originally posted by @vhvb1989 in #5733 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions