stepmeta

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2026 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	PatchCommandToolSchema                      = patchCommandToolSchema
	PatchWriteContainerdConfigToolSchema        = patchWriteContainerdConfigToolSchema
	PatchWriteContainerdRegistryHostsToolSchema = patchWriteContainerdRegistryHostsToolSchema
	PatchEnsureDirectoryToolSchema              = patchEnsureDirectoryToolSchema
	PatchDownloadImageToolSchema                = patchDownloadImageToolSchema
	PatchImageLoadToolSchema                    = patchImageLoadToolSchema
	PatchVerifyImageToolSchema                  = patchVerifyImageToolSchema
	PatchCheckHostToolSchema                    = patchCheckHostToolSchema
	PatchKernelModuleToolSchema                 = patchKernelModuleToolSchema
	PatchInitKubeadmToolSchema                  = patchInitKubeadmToolSchema
	PatchJoinKubeadmToolSchema                  = patchJoinKubeadmToolSchema
	PatchResetKubeadmToolSchema                 = patchResetKubeadmToolSchema
	PatchUpgradeKubeadmToolSchema               = patchUpgradeKubeadmToolSchema
	PatchCheckKubernetesClusterToolSchema       = patchCheckKubernetesClusterToolSchema
	PatchMessageToolSchema                      = patchMessageToolSchema
	PatchConfirmToolSchema                      = patchConfirmToolSchema
	PatchInputToolSchema                        = patchInputToolSchema
)
View Source
var (
	PatchDownloadFileToolSchema          = patchDownloadFileToolSchema
	PatchWriteFileToolSchema             = patchWriteFileToolSchema
	PatchCopyFileToolSchema              = patchCopyFileToolSchema
	PatchExtractArchiveToolSchema        = patchExtractArchiveToolSchema
	PatchEditFileToolSchema              = patchEditFileToolSchema
	PatchEditTOMLToolSchema              = patchEditTOMLToolSchema
	PatchEditYAMLToolSchema              = patchEditYAMLToolSchema
	PatchEditJSONToolSchema              = patchEditJSONToolSchema
	PatchStructuredEditToolSchema        = patchStructuredEditToolSchema
	PatchWaitForServiceToolSchema        = patchWaitForServiceToolSchema
	PatchWaitForCommandToolSchema        = patchWaitForCommandToolSchema
	PatchWaitForFileToolSchema           = patchWaitForFileToolSchema
	PatchWaitForMissingFileToolSchema    = patchWaitForMissingFileToolSchema
	PatchWaitForTCPPortToolSchema        = patchWaitForTCPPortToolSchema
	PatchWaitForMissingTCPPortToolSchema = patchWaitForMissingTCPPortToolSchema
	PatchWaitToolSchema                  = patchWaitToolSchema
)
View Source
var (
	PatchRefreshRepositoryToolSchema   = patchRefreshRepositoryToolSchema
	PatchDownloadPackageToolSchema     = patchDownloadPackageToolSchema
	PatchInstallPackageToolSchema      = patchInstallPackageToolSchema
	PatchInstallAptPackageToolSchema   = patchInstallAptPackageToolSchema
	PatchInstallDnfPackageToolSchema   = patchInstallDnfPackageToolSchema
	PatchConfigureRepositoryToolSchema = patchConfigureRepositoryToolSchema
)
View Source
var (
	PatchManageServiceToolSchema    = patchManageServiceToolSchema
	PatchSwapToolSchema             = patchSwapToolSchema
	PatchCreateSymlinkToolSchema    = patchCreateSymlinkToolSchema
	PatchSysctlToolSchema           = patchSysctlToolSchema
	PatchWriteSystemdUnitToolSchema = patchWriteSystemdUnitToolSchema
)

Functions

func CategoryForEntry added in v0.2.2

func CategoryForEntry(entry Entry) string

func MustRegister

func MustRegister[T any](def Definition) struct{}

func ProjectRuntimeOutputs added in v0.2.2

func ProjectRuntimeOutputs(entry Entry, rendered map[string]any, runtime map[string]any, opts RuntimeOutputOptions) map[string]any

func ProjectRuntimeOutputsForKind added in v0.2.2

func ProjectRuntimeOutputsForKind(kind string, rendered map[string]any, runtime map[string]any, opts RuntimeOutputOptions) (map[string]any, error)

func RegisterSourceFS

func RegisterSourceFS(source fs.FS) struct{}

func RegisteredKinds

func RegisteredKinds() []string

Types

type AskMetadata

type AskMetadata struct {
	Capabilities             []string
	ContractHints            ContractHints
	Builders                 []AuthoringBuilder
	MatchSignals             []string
	KeyFields                []string
	ValidationHints          []ValidationHint
	ConstrainedLiteralFields []ConstrainedLiteralField
	QualityRules             []QualityRule
	AntiSignals              []string
}

func ProjectAsk

func ProjectAsk(entry Entry) AskMetadata

type AuthoringBinding added in v0.2.1

type AuthoringBinding struct {
	Path     string
	From     string
	Semantic string
	Required bool
}

type AuthoringBuilder added in v0.2.1

type AuthoringBuilder struct {
	ID                   string
	Phase                string
	DefaultStepID        string
	Summary              string
	RequiresCapabilities []string
	Bindings             []AuthoringBinding
}

type ConstrainedLiteralField

type ConstrainedLiteralField struct {
	Path          string
	AllowedValues []string
	Guidance      string
}

type ContractHints added in v0.2.1

type ContractHints struct {
	ProducesArtifacts   []string
	ConsumesArtifacts   []string
	PublishesState      []string
	ConsumesState       []string
	RoleSensitive       bool
	VerificationRelated bool
}

type Definition

type Definition struct {
	Kind        string
	Family      string
	FamilyTitle string
	Category    string
	Group       string
	GroupOrder  int
	DocsPage    string
	DocsOrder   int
	Visibility  string
	Roles       []string
	Outputs     []string
	SchemaFile  string
	SchemaPatch func(root map[string]any)
	Summary     string
	WhenToUse   string
	Example     string
	Notes       []string
	Parallel    ParallelMetadata
	Ask         AskMetadata
}

type Docs

type Docs struct {
	Summary   string
	WhenToUse string
	Example   string
	Notes     []string
	Fields    []FieldDoc
	Source    SourceRef
}

type Entry

type Entry struct {
	Definition Definition
	TypeName   string
	Docs       Docs
	Schema     Schema
}

func Lookup

func Lookup(kind string) (Entry, bool, error)

type FieldDoc

type FieldDoc struct {
	Path        string
	Description string
	Example     string
	Required    bool
	Hidden      bool
	Source      SourceRef
}

type OutputRootConstraint added in v0.2.3

type OutputRootConstraint struct {
	Path    string
	Root    string
	Example string
}

type ParallelMetadata added in v0.2.3

type ParallelMetadata struct {
	ApplySafe        bool
	ApplyTargetPaths []string
	PrepareOutput    OutputRootConstraint
}

type QualityRule

type QualityRule struct {
	Trigger string
	Message string
	Level   string
}

type RuntimeOutputOptions added in v0.2.2

type RuntimeOutputOptions struct {
	FileExists func(path string) bool
}

type Schema

type Schema struct {
	SpecType any
	Patch    func(root map[string]any)
	Source   SourceRef
}

type SchemaProjection

type SchemaProjection struct {
	SpecType any
	Patch    func(root map[string]any)
	Source   SourceRef
}

func ProjectSchema

func ProjectSchema(entry Entry) SchemaProjection

type SourceRef

type SourceRef struct {
	File string
	Line int
}

type StepCatalogEntry

type StepCatalogEntry = Entry

StepCatalogEntry is the explicit source-of-truth entry consumed by workflow, schema, docs, and ask projections.

func LookupCatalogEntry

func LookupCatalogEntry(kind string) (StepCatalogEntry, bool, error)

type ToolProjection

type ToolProjection struct {
	Kind      string
	Category  string
	Summary   string
	WhenToUse string
	Example   string
	Notes     []string
	FieldDocs map[string]FieldDoc
}

func ProjectTool

func ProjectTool(entry Entry) ToolProjection

type ValidationHint

type ValidationHint struct {
	ErrorContains string
	Fix           string
}

type WorkflowProjection

type WorkflowProjection struct {
	Kind        string
	Family      string
	FamilyTitle string
	Group       string
	GroupOrder  int
	DocsPage    string
	DocsOrder   int
	SchemaFile  string
	Visibility  string
	Category    string
	Summary     string
	WhenToUse   string
	Roles       []string
	Outputs     []string
	Parallel    ParallelMetadata
	Generator   string
}

func ProjectWorkflow

func ProjectWorkflow(entry Entry, generator string) WorkflowProjection

Jump to

Keyboard shortcuts

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