Documentation
¶
Index ¶
- Constants
- func AddLocalFlag(command *cobra.Command, local *bool) string
- func AddOfflineFlag(command *cobra.Command, offline *bool) string
- func AddRevisionFlag(command *cobra.Command, revision *string) string
- func ProviderIds(providerFlags []ProviderFlag) map[ProviderFlag][]string
- func ProviderValues(providerIds map[ProviderFlag][]string) []string
- type ProviderFlag
- type SourceFlag
Constants ¶
View Source
const ( NoneFlagShortHand = "" ErrorFlagNotSupported = "flag not supported" )
View Source
const ( RevisionFlagName = "revision" LocalFlagName = "local" OfflineFlagName = "offline" )
View Source
const (
UnknownProvider = "unknown"
)
Variables ¶
This section is empty.
Functions ¶
func ProviderIds ¶
func ProviderIds(providerFlags []ProviderFlag) map[ProviderFlag][]string
ProviderIds builds a subset of all the available providers, required for the enum flag
func ProviderValues ¶
func ProviderValues(providerIds map[ProviderFlag][]string) []string
ProviderValues builds a list of labels to concatenate, required for the flag usage
Types ¶
type ProviderFlag ¶
const ( UnknownProviderFlag ProviderFlag = iota DockerProviderFlag KubeProviderFlag CloudProviderFlag )
func ExistProvider ¶
func ExistProvider(providerIds map[ProviderFlag][]string, value string) (ProviderFlag, error)
ExistProvider verify if the given string is a valid provider
func (ProviderFlag) String ¶
func (p ProviderFlag) String() string
type SourceFlag ¶
func AddTemplateSourceFlag ¶
func AddTemplateSourceFlag(command *cobra.Command) *SourceFlag
Click to show internal directories.
Click to hide internal directories.