(f *pflag.FlagSet)
| 222 | } |
| 223 | |
| 224 | func (o *ProjectOptions) addProjectFlags(f *pflag.FlagSet) { |
| 225 | f.StringArrayVar(&o.Profiles, "profile", []string{}, "Specify a profile to enable") |
| 226 | f.StringVarP(&o.ProjectName, "project-name", "p", "", "Project name") |
| 227 | f.StringArrayVarP(&o.ConfigPaths, "file", "f", []string{}, "Compose configuration files") |
| 228 | f.StringArrayVar(&o.insecureRegistries, "insecure-registry", []string{}, "Use insecure registry to pull Compose OCI artifacts. Doesn't apply to images") |
| 229 | _ = f.MarkHidden("insecure-registry") |
| 230 | f.StringArrayVar(&o.EnvFiles, "env-file", defaultStringArrayVar(ComposeEnvFiles), "Specify an alternate environment file") |
| 231 | f.StringVar(&o.ProjectDir, "project-directory", "", "Specify an alternate working directory\n(default: the path of the, first specified, Compose file)") |
| 232 | f.StringVar(&o.WorkDir, "workdir", "", "DEPRECATED! USE --project-directory INSTEAD.\nSpecify an alternate working directory\n(default: the path of the, first specified, Compose file)") |
| 233 | f.BoolVar(&o.Compatibility, "compatibility", false, "Run compose in backward compatibility mode") |
| 234 | f.StringVar(&o.Progress, "progress", os.Getenv(ComposeProgress), fmt.Sprintf(`Set type of progress output (%s)`, strings.Join(printerModes, ", "))) |
| 235 | f.BoolVar(&o.All, "all-resources", false, "Include all resources, even those not used by services") |
| 236 | _ = f.MarkHidden("workdir") |
| 237 | } |
| 238 | |
| 239 | // get default value for a command line flag that is set by a coma-separated value in environment variable |
| 240 | func defaultStringArrayVar(env string) []string { |
no test coverage detected