tmpl

package
v0.27.0 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2018 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewFileRenderer added in v0.25.2

func NewFileRenderer(readFile func(filename string) ([]byte, error), basePath string) *templateFileRenderer

func RequiredEnv

func RequiredEnv(name string) (string, error)

func ToYaml

func ToYaml(v interface{}) (string, error)

Types

type Context

type Context struct {
	// contains filtered or unexported fields
}

func (*Context) ReadFile

func (c *Context) ReadFile(filename string) (string, error)

func (*Context) RenderTemplateToBuffer

func (c *Context) RenderTemplateToBuffer(s string) (*bytes.Buffer, error)

type FileRenderer added in v0.25.2

type FileRenderer interface {
	RenderTemplateFileToBuffer(file string) (*bytes.Buffer, error)
}

type Values

type Values = map[string]interface{}

func FromYaml

func FromYaml(str string) (Values, error)

func SetValueAtPath

func SetValueAtPath(path string, value interface{}, values Values) (Values, error)

Jump to

Keyboard shortcuts

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