yaml

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyFixedValueToDynamicFieleds

func ApplyFixedValueToDynamicFieleds(t v1alpha1.SnapshotConfig, docs []*yaml.RNode) error

func Decode

func Decode(bs []byte) (out []*yaml.RNode, err error)

func Encode

func Encode(resources []*yaml.RNode) ([]byte, error)

func Replace

func Replace(doc *yaml.RNode, path, value string) error

Replace replaces the value at the given jsonpath with the given value. jsonpath is a RFC 6901 JSON path.

func SetLogger

func SetLogger(slogr *slog.Logger)

Types

type DiffOptions

type DiffOptions struct {
	ContextLineN int
}

func MergeDiffOptions

func MergeDiffOptions(opts []DiffOptions) DiffOptions

func (*DiffOptions) Diff

func (o *DiffOptions) Diff(x, y string) string

Jump to

Keyboard shortcuts

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