本文整理汇总了Golang中github.com/apex/apex/cmd/apex/root.Register函数的典型用法代码示例。如果您正苦于以下问题:Golang Register函数的具体用法?Golang Register怎么用?Golang Register使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了Register函数的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。
示例1: init
// Initialize.
func init() {
root.Register(Command)
f := Command.Flags()
f.StringVarP(&envFile, "env-file", "E", "", "Set environment variables from JSON file")
f.StringSliceVarP(&env, "set", "s", nil, "Set environment variable")
}
示例2: init
// Initialize.
func init() {
root.Register(Command)
f := Command.Flags()
f.StringVarP(&alias, "alias", "a", "current", "Function alias")
f.StringVarP(&version, "version", "v", "", "version to which rollback is done")
}
示例3: init
// Initialize.
func init() {
root.Register(Command)
f := Command.Flags()
f.BoolVarP(&includeLogs, "logs", "L", false, "Print logs")
f.StringVarP(&alias, "alias", "a", "current", "Function alias")
}
示例4: init
// Initialize.
func init() {
root.Register(Command)
f := Command.Flags()
f.DurationVarP(&duration, "since", "s", 5*time.Minute, "Start time of the search")
f.StringVarP(&filter, "filter", "F", "", "Filter logs with pattern")
f.BoolVarP(&follow, "follow", "f", false, "Follow tails logs for updates")
}
示例5: init
// Initialize.
func init() {
root.Register(Command)
f := Command.Flags()
f.StringSliceVarP(&env, "env", "e", nil, "Environment variable")
f.StringVarP(&alias, "alias", "a", "current", "Function alias")
f.IntVarP(&concurrency, "concurrency", "c", 5, "Concurrent deploys")
}
示例6: init
// Initialize.
func init() {
root.Register(Command)
}
示例7: init
// Initialize.
func init() {
root.Register(Command)
f := Command.Flags()
f.DurationVarP(&duration, "since", "s", 24*time.Hour, "Start time of the results")
}
示例8: init
// Initialize.
func init() {
root.Register(Command)
f := Command.Flags()
f.BoolVarP(&force, "force", "f", false, "Force deletion")
}
示例9: init
// Initialize.
func init() {
root.Register(Command)
f := Command.Flags()
f.BoolVar(&tfvars, "tfvars", false, "Output as Terraform variables")
}
示例10: init
// Initialize.
func init() {
root.Register(Command)
f := Command.Flags()
f.BoolVarP(&includeLogs, "logs", "L", false, "Print logs")
}
示例11: init
// Initialize.
func init() {
root.Register(Command)
f := Command.Flags()
f.IntVarP(&concurrency, "concurrency", "c", 5, "Concurrent deploys")
}