🐛 修正参数

This commit is contained in:
徐晓伟 2024-01-16 11:02:37 +08:00
parent c63941d072
commit 741e281185
3 changed files with 12 additions and 16 deletions

View File

@ -623,12 +623,10 @@ COPYRIGHT:
--base-url value 实例地址例如https://gitlab.xuxiaowei.com.cn/api/v4 (default: "https://gitlab.com/api/v4") [%CI_API_V4_URL%]
--token value your_access_token
--owned 当前用户明确拥有的项目。 (default: false)
--skip-project-path value [ --skip-project-path value ] 跳过项目路径
--skip-project-wiki-path value [ --skip-project-wiki-path value ] 跳过项目wiki路径
--allow-failure 允许失败 (default: false)
--name value 环境名称
--external-url value 该环境的链接位置
--tier value 新环境的层级。允许设置的值为 production staging testing development 和 other
--allow-failure 允许失败 (default: false)
--print-json 打印 JSON (default: false)
--print-time 打印时间 (default: false)
--help, -h show help

View File

@ -16,8 +16,7 @@ func EnvironmentsCreateAll() *cli.Command {
Aliases: []string{"a"},
Usage: "所有项目创建新环境",
Flags: append(flag.CommonTokenRequired(), flag.Owned(true),
flag.SkipProjectPath(), flag.SkipProjectWikiPath(), flag.AllowFailure(),
flag.EnvName(false), flag.EnvExternalUrl(), flag.EnvTier(),
flag.EnvName(false), flag.EnvExternalUrl(), flag.EnvTier(), flag.AllowFailure(),
flag.PrintJson(), flag.PrintTime()),
Action: func(context *cli.Context) error {
var baseUrl = context.String(constant.BaseUrl)

View File

@ -11,8 +11,7 @@ func Environments() *cli.Command {
Aliases: []string{"mix-create-environment", "mix-create-env"},
Usage: "创建新环境(混合命令,多接口命令)",
Flags: append(flag.Common(), flag.Owned(false),
flag.SkipProjectPath(), flag.SkipProjectWikiPath(), flag.AllowFailure(),
flag.EnvName(false), flag.EnvExternalUrl(), flag.EnvTier(),
flag.EnvName(false), flag.EnvExternalUrl(), flag.EnvTier(), flag.AllowFailure(),
flag.PrintJson(), flag.PrintTime()),
Subcommands: []*cli.Command{
EnvironmentsCreateAll(),