Add comments to public structs
Signed-off-by: Alex Ellis (OpenFaaS Ltd) <alexellis2@gmail.com>
This commit is contained in:
@@ -46,16 +46,16 @@ func (i *BuildFormat) String() string {
|
||||
}
|
||||
|
||||
// Set implements pflag.Value
|
||||
func (l *BuildFormat) Set(value string) error {
|
||||
func (i *BuildFormat) Set(value string) error {
|
||||
switch strings.ToLower(value) {
|
||||
case "", "default", "latest":
|
||||
*l = DefaultFormat
|
||||
*i = DefaultFormat
|
||||
case "sha":
|
||||
*l = SHAFormat
|
||||
*i = SHAFormat
|
||||
case "branch":
|
||||
*l = BranchAndSHAFormat
|
||||
*i = BranchAndSHAFormat
|
||||
case "describe":
|
||||
*l = DescribeFormat
|
||||
*i = DescribeFormat
|
||||
default:
|
||||
return fmt.Errorf("unknown image tag format: '%s'", value)
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
package schema
|
||||
|
||||
//Metadata metadata of the object
|
||||
// Metadata metadata of the object
|
||||
type Metadata struct {
|
||||
Name string `yaml:"name"`
|
||||
Namespace string `yaml:"namespace,omitempty"`
|
||||
|
||||
Reference in New Issue
Block a user