yamltags

package
v1.19.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 28, 2021 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetYamlTag added in v1.7.1

func GetYamlTag(value interface{}) string

GetYamlTag returns the first yaml tag used in the raw yaml text of the given struct

func GetYamlTags added in v1.18.0

func GetYamlTags(value interface{}) []string

GetYamlTags returns the tags of the non-nested fields of the given non-nil value If value interface{} is latest.DeployType{HelmDeploy: &HelmDeploy{...}, KustomizeDeploy: &KustomizeDeploy{...}} then this parses that interface as it's raw yaml:

	kubectl:
   manifests:
   - k8s/*.yaml
 kustomize:
   paths:
   - k8s/

and returns ["kubectl", "kustomize"] empty structs (e.g. latest.DeployType{}) when parsed look like "{}"" and so this function returns []

func ValidateStruct added in v0.28.0

func ValidateStruct(s interface{}) error

ValidateStruct validates and processes the provided pointer to a struct.

func YamlName added in v0.37.0

func YamlName(field reflect.StructField) string

YamlName returns the YAML name of the given field

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL