templates

package
v5.8.3+incompatible Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var IdentifierInvalidRe = regexp.MustCompile("[^a-z0-9]+")

Matches all invalid chars from rfc1035/rfc1123. See also: https://github.com/kubernetes/community/blob/master/contributors/design-proposals/identifiers.md

Functions

func IdentifierFunc

func IdentifierFunc(s string) string

func MakeSliceFunc

func MakeSliceFunc(elements ...interface{}) []interface{}

Example: https://stackoverflow.com/a/25013152/393157

func Render

func Render(templateString string, variables Variables) (string, error)

func RenderAll

func RenderAll(templates []gh.File, variables Variables) ([]gh.File, error)

Types

type Variables

type Variables map[string]string

func (*Variables) Defaults

func (v *Variables) Defaults(defaults Variables)

Jump to

Keyboard shortcuts

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