dded flag --suppress-warnings, --verbose, --error-on-warning global flags

- `--suppress-warnings` it ignores all warnings.
- `--verbose` displays everything
- `--error-on-warning` with any warning exits displaying error.

Fixes #100
This commit is contained in:
Suraj Deshmukh
2016-09-16 10:37:43 +05:30
parent 4b3fbc02a5
commit 57c460cc50
2 changed files with 33 additions and 0 deletions
+15
View File
@@ -124,5 +124,20 @@ func CommonFlags() []cli.Flag {
Value: app.DefaultComposeFile,
EnvVar: "COMPOSE_FILE",
},
// creating a flag to suppress warnings
cli.BoolFlag{
Name: "suppress-warnings",
Usage: "Suppress all warnings",
},
// creating a flag to show all kinds of warnings
cli.BoolFlag{
Name: "verbose",
Usage: "Show all type of logs",
},
// flag to treat any warning as error
cli.BoolFlag{
Name: "error-on-warning",
Usage: "Treat any warning as error",
},
}
}