INNER CODE UNIT · Go

addCommandWithGroup

easegress-io/easegress · cmd/builder/main.go:43

	addCommandWithGroup := func(group *cobra.Group, cmd ...*cobra.Command) {
		for _, c := range cmd {
			c.GroupID = group.ID
		}
		rootCmd.AddCommand(cmd...)
	}

	addCommandWithGroup(
		basicGroup,
		command.InitCmd(),
		command.AddCmd(),
		command.BuildCmd(),
		command.RunCmd(),
	)

	rootCmd.AddGroup(basicGroup)

	rootCmd.SilenceErrors = true

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…