Just expose a single Flags function

This commit is contained in:
Don 2019-10-11 16:21:11 -07:00
parent 0324ae7edb
commit 4914fdebc7

View File

@ -24,7 +24,7 @@
// } // }
// app.Flags = append( // app.Flags = append(
// app.Flags, // app.Flags,
// urfave.PipelineFlags()..., // urfave.Flags()...,
// ) // )
// } // }
// //
@ -44,11 +44,26 @@ import (
) )
//--------------------------------------------------------------------- //---------------------------------------------------------------------
// Pipeline // Flags
//--------------------------------------------------------------------- //---------------------------------------------------------------------
// PipelineFlags has the cli.Flags for the plugin.Pipeline. // Flags for a urfave cli Drone plugin
func PipelineFlags() []cli.Flag { func Flags() []cli.Flag {
flags := []cli.Flag{}
flags = append(flags, pipelineFlags()...)
flags = append(flags, networkFlags()...)
flags = append(flags, loggingFlags()...)
return flags
}
//---------------------------------------------------------------------
// Pipeline flags
//---------------------------------------------------------------------
// pipelineFlags has the cli.Flags for the plugin.Pipeline.
func pipelineFlags() []cli.Flag {
flags := []cli.Flag{} flags := []cli.Flag{}
flags = append(flags, buildFlags()...) flags = append(flags, buildFlags()...)
@ -57,7 +72,6 @@ func PipelineFlags() []cli.Flag {
flags = append(flags, stageFlags()...) flags = append(flags, stageFlags()...)
flags = append(flags, stepFlags()...) flags = append(flags, stepFlags()...)
flags = append(flags, semVerFlags()...) flags = append(flags, semVerFlags()...)
flags = append(flags, loggingFlags()...)
return flags return flags
} }