You can not select more than 25 topics
Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
- package cmdline
-
- import (
- "github.com/spf13/cobra"
- "gitlink.org.cn/cloudream/jcs-pub/client/internal/services"
- )
-
- type CommandContext struct {
- svc *services.Service
- }
-
- var RootCmd = cobra.Command{}
-
- func GetCmdCtx(cmd *cobra.Command) *CommandContext {
- return cmd.Context().Value("cmdCtx").(*CommandContext)
- }
-
- func RootExecute() {
- RootCmd.Execute()
- }
|