MCPcopy Create free account
hub / github.com/docker/cli / New

Function New

templates/templates.go:71–73  ·  view source on GitHub ↗

New creates a new empty template with the provided tag and built-in template functions.

(tag string)

Source from the content-addressed store, hash-verified

69// New creates a new empty template with the provided tag and built-in
70// template functions.
71func New(tag string) *template.Template {
72 return template.New(tag).Funcs(basicFunctions)
73}
74
75// padWithSpace adds whitespace to the input if the input is non-empty
76func padWithSpace(source string, prefix, suffix int) string {

Callers 3

TestNewParseFunction · 0.70
TestHeaderFunctionsFunction · 0.70
TestJoinElementsFunction · 0.70

Calls

no outgoing calls

Tested by 3

TestNewParseFunction · 0.56
TestHeaderFunctionsFunction · 0.56
TestJoinElementsFunction · 0.56