mirror of
https://github.com/drone/drone-cli.git
synced 2024-06-08 15:06:04 +02:00
Merge branch 'master' of github.com:drone/drone-cli into feature/template-config
This commit is contained in:
commit
59a1b33230
|
@ -41,7 +41,7 @@ var Command = cli.Command{
|
|||
Name: "stream",
|
||||
Usage: "Write output as a YAML stream.",
|
||||
},
|
||||
cli.BoolTFlag{
|
||||
cli.BoolFlag{
|
||||
Name: "format",
|
||||
Usage: "Write output as formatted YAML",
|
||||
},
|
||||
|
@ -109,9 +109,8 @@ func generate(c *cli.Context) error {
|
|||
buf.WriteString(result)
|
||||
}
|
||||
|
||||
// the yaml file is parsed and formatted by default. This
|
||||
// can be disabled for --format=false.
|
||||
if c.BoolT("format") {
|
||||
// enable yaml formatting with --format
|
||||
if c.Bool("format") {
|
||||
manifest, err := yaml.Parse(buf)
|
||||
if err != nil {
|
||||
return err
|
||||
|
|
Loading…
Reference in New Issue