agentguide

package
v1.7.0 Latest Latest
Warning

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

Go to latest
Published: May 15, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package agentguide holds the curated order of the user-facing guide sections shipped by `tkn-act agent-guide`. Both the generator (internal/agentguide-gen) and the embedding command (agentguide.go) import this list so the two cannot drift.

Index

Constants

This section is empty.

Variables

View Source
var Order = []string{
	"overview",
	"docker-backend",
	"step-template",
	"sidecars",
	"step-actions",
	"matrix",
	"pipeline-results",
	"display-name",
	"timeouts",
	"resolvers",
}

Order is the curated concatenation order for the user-guide files under docs/agent-guide/. Each entry is the base name without the `.md` suffix; "overview" is the alias for README.md.

When concatenated into the default `tkn-act agent-guide` output, adjacent files are separated by a horizontal-rule block ("---") matching the existing in-section separators in the source files.

Functions

func FileName

func FileName(section string) string

FileName returns the on-disk file name for a section in Order. The alias "overview" maps to README.md; every other section maps to `<section>.md`.

func Generate

func Generate(src, dst string) error

Generate mirrors the user-guide files under src into dst, in canonical form: each destination file holds exactly the source's content trimmed to one trailing newline. Source files are validated against Order — every entry must be present, and no extra .md files may exist alongside.

Any non-canonical entry already living under dst (stale .md files from a rename, non-markdown leftovers, subdirectories) is removed, so a clean regenerate produces a tree that mirrors Order exactly.

Generate is the single implementation shared by `agentguide-gen` (the generator binary invoked from `go generate ./cmd/tkn-act/`) and the freshness test under cmd/tkn-act/, so the two cannot drift in behavior.

func Sections

func Sections() []string

Sections returns a copy of Order so callers can iterate without risking mutation of the package-level slice.

Types

This section is empty.

Jump to

Keyboard shortcuts

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