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.

ticktock.go 489 B

12345678910111213141516171819202122232425
  1. package repl
  2. import "github.com/spf13/cobra"
  3. func init() {
  4. ttCmd := &cobra.Command{
  5. Use: "ticktock",
  6. Short: "ticktock command",
  7. }
  8. RootCmd.AddCommand(ttCmd)
  9. runCmd := &cobra.Command{
  10. Use: "run [jobName]",
  11. Short: "run job now",
  12. Args: cobra.ExactArgs(1),
  13. Run: func(cmd *cobra.Command, args []string) {
  14. tickTockRun(GetCmdCtx(cmd), args[0])
  15. },
  16. }
  17. ttCmd.AddCommand(runCmd)
  18. }
  19. func tickTockRun(ctx *CommandContext, jobName string) {
  20. ctx.repl.tktk.RunNow(jobName)
  21. }

本项目旨在将云际存储公共基础设施化,使个人及企业可低门槛使用高效的云际存储服务(安装开箱即用云际存储客户端即可,无需关注其他组件的部署),同时支持用户灵活便捷定制云际存储的功能细节。