forked from LaconicNetwork/kompose
make --file as global flag
This commit is contained in:
+8
-19
@@ -32,12 +32,6 @@ func ConvertCommand() cli.Command {
|
||||
app.Convert(c)
|
||||
},
|
||||
Flags: []cli.Flag{
|
||||
cli.StringFlag{
|
||||
Name: "file,f",
|
||||
Usage: fmt.Sprintf("Specify an alternate compose file (default: %s)", app.DefaultComposeFile),
|
||||
Value: app.DefaultComposeFile,
|
||||
EnvVar: "COMPOSE_FILE",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "bundle,dab",
|
||||
Usage: "Specify a Distributed Application Bundle (DAB) file",
|
||||
@@ -94,12 +88,6 @@ func UpCommand() cli.Command {
|
||||
app.Up(c)
|
||||
},
|
||||
Flags: []cli.Flag{
|
||||
cli.StringFlag{
|
||||
Name: "file,f",
|
||||
Usage: fmt.Sprintf("Specify an alternative compose file (default: %s)", app.DefaultComposeFile),
|
||||
Value: app.DefaultComposeFile,
|
||||
EnvVar: "COMPOSE_FILE",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "bundle,dab",
|
||||
Usage: "Specify a Distributed Application Bundle (DAB) file",
|
||||
@@ -118,12 +106,6 @@ func DownCommand() cli.Command {
|
||||
app.Down(c)
|
||||
},
|
||||
Flags: []cli.Flag{
|
||||
cli.StringFlag{
|
||||
Name: "file,f",
|
||||
Usage: fmt.Sprintf("Specify an alternative compose file (default: %s)", app.DefaultComposeFile),
|
||||
Value: app.DefaultComposeFile,
|
||||
EnvVar: "COMPOSE_FILE",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "bundle,dab",
|
||||
Usage: "Specify a Distributed Application Bundle (DAB) file",
|
||||
@@ -135,5 +117,12 @@ func DownCommand() cli.Command {
|
||||
|
||||
// CommonFlags defines the flags that are in common for all subcommands.
|
||||
func CommonFlags() []cli.Flag {
|
||||
return []cli.Flag{}
|
||||
return []cli.Flag{
|
||||
cli.StringFlag{
|
||||
Name: "file,f",
|
||||
Usage: fmt.Sprintf("Specify an alternative compose file (default: %s)", app.DefaultComposeFile),
|
||||
Value: app.DefaultComposeFile,
|
||||
EnvVar: "COMPOSE_FILE",
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user