tmpl

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2018 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const TmplYamlName = "tmpl.yaml"

Variables

This section is empty.

Functions

func FillVariables added in v0.4.0

func FillVariables(dirPath string, enableYamlParse bool) error

func GetReservedVariables

func GetReservedVariables(enableYamlParse bool) map[string]interface{}

func InputVariables

func InputVariables(prompt yaml.MapSlice, enableYamlParse bool) map[string]interface{}

func ReplaceInDir

func ReplaceInDir(dirPath string, variables map[string]interface{}) error

Types

type TmplYaml

type TmplYaml struct {
	// NOTE: yaml.MapSlice preserves the order of items
	// (from: https://stackoverflow.com/a/42109240/2885946)
	Variables yaml.MapSlice `yaml:variables`
}

func ReadTemplYaml

func ReadTemplYaml(dirPath string) (TmplYaml, error)

Jump to

Keyboard shortcuts

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