MCPcopy Create free account
hub / github.com/drone/envsubst / ParseFile

Function ParseFile

template.go:40–46  ·  view source on GitHub ↗

ParseFile creates a new shell format template and parses the template definition from the named file.

(path string)

Source from the content-addressed store, hash-verified

38// ParseFile creates a new shell format template and parses the template
39// definition from the named file.
40func ParseFile(path string) (*Template, error) {
41 b, err := ioutil.ReadFile(path)
42 if err != nil {
43 return nil, err
44 }
45 return Parse(string(b))
46}
47
48// Execute applies a parsed template to the specified data mapping.
49func (t *Template) Execute(mapping func(string) string) (str string, err error) {

Callers

nothing calls this directly

Calls 1

ParseFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…