demo

package
v0.0.0-...-8d54ad1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 2, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Foo1Command = &cobra.Command{
	Use:     "foo1",
	Short:   "foo1的简要说明",
	Long:    "foo1的长说明",
	Aliases: []string{"fo1", "f1"},
	Example: "foo1命令的例子",
	RunE: func(c *cobra.Command, args []string) error {
		container := c.GetContainer()
		log.Println(container)
		return nil
	},
}

Foo1Command 代表Foo命令的子命令Foo1

View Source
var FooCommand = &cobra.Command{
	Use:     "foo",
	Short:   "foo的简要说明",
	Long:    "foo的长说明",
	Aliases: []string{"fo", "f"},
	Example: "foo命令的例子",
	RunE: func(c *cobra.Command, args []string) error {
		container := c.GetContainer()
		log.Println(container)
		log.Println("execute foo command")
		return nil
	},
}

FooCommand 代表Foo命令

View Source
var FooCornCommand = &cobra.Command{
	Use:     "fcorn",
	Short:   "fcorn的简要说明",
	Long:    "fcorn的长说明",
	Aliases: []string{"fcorn", "fc"},
	Example: "foo命令的例子",
	RunE: func(c *cobra.Command, args []string) error {
		log.Println("execute fcorn command")
		return nil
	},
}

FooCommand 代表Foo命令

Functions

func InitFoo

func InitFoo() *cobra.Command

InitFoo 初始化Foo命令

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL