sources

package
v0.7.2 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decode

func Decode(reader io.Reader) ([]unstructured.Unstructured, error)

decode consumes the given reader and parses its contents as YAML.

func Parse

func Parse(pathname string, recursive bool) ([]unstructured.Unstructured, error)

Parse parses YAML files into Unstructured objects.

It supports 5 cases today:

  1. pathname = path to a file --> parses that file.
  2. pathname = path to a directory, recursive = false --> parses all files in that directory.
  3. pathname = path to a directory, recursive = true --> parses all files in that directory and it's descendants
  4. pathname = url --> fetches the contents of that URL and parses them as YAML.
  5. pathname = combination of all previous cases, the string can contain multiple records (file, directory or url) separated by comma

Types

This section is empty.

Jump to

Keyboard shortcuts

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