Help us shape the future of Go! Take the 2026 Go Developer Survey

template

package
v0.39.0 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Render

func Render(tmpl string, ctx *Context) (string, error)

Render resolves template expressions in the given string. Uses Go's text/template syntax: {{.TaskName}}, {{.Vars.myvar}}. Returns the input unchanged if it contains no template delimiters.

Types

type Context

type Context struct {
	// System variables
	JobID     string
	TaskName  string
	Iteration int
	Attempt   int
	Timestamp string

	// User-defined variables (from inputs section or CSV)
	Vars map[string]string
}

Context holds all variables available for template resolution.

Jump to

Keyboard shortcuts

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