helper

package
v0.9.14 Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddStringBeforePointForKindAndName added in v0.9.14

func AddStringBeforePointForKindAndName(filePath, kind, name, point, addContent string) error

func AddStringObjectToYaml added in v0.9.14

func AddStringObjectToYaml(path string, str string) error

func AddStringToYaml added in v0.5.0

func AddStringToYaml(path string, str string) error

func AddStructToYaml added in v0.4.4

func AddStructToYaml(path string, struc interface{}) error

func AddYamlToYaml added in v0.5.2

func AddYamlToYaml(filePath, addFilePath string) error

func DeleteKindFromYaml added in v0.5.2

func DeleteKindFromYaml(path string, kind string) error

func GetAbsPath added in v0.9.14

func GetAbsPath(pathParts ...string) (string, error)

func GetApiGroupFromYaml added in v0.9.0

func GetApiGroupFromYaml(filePath string) (string, error)

func GetVersionFromYaml

func GetVersionFromYaml(filePath string) (string, error)

func Run

func Run(logger logging.Logger, cmd exec.Cmd) error

func StructToYaml

func StructToYaml(struc interface{}, path string) error

func YamlToString added in v0.7.7

func YamlToString(path string) (string, error)

func YamlToStruct

func YamlToStruct(path string, struc interface{}) error

Types

type Metadata added in v0.9.14

type Metadata struct {
	Name string `yaml:"name"`
}

type Resource

type Resource struct {
	Kind       string    `yaml:"kind"`
	ApiVersion string    `yaml:"apiVersion"`
	Metadata   *Metadata `yaml:"metadata"`
}

Jump to

Keyboard shortcuts

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