Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CopyToTask ¶
CopyToTask copies WORKFLOW.yaml to a task folder. Reads from local override or embedded template.
func FormatProgression ¶
FormatProgression formats stage names with current stage in parentheses. Example: "plan → (implement) → review → ready"
func TemplateDir ¶
TemplateDir returns the path to a workflow template directory.
func WorkflowsDir ¶
func WorkflowsDir() string
WorkflowsDir returns the path to the workflows directory.
Types ¶
type Instructions ¶
Instructions contains guidance for lead and worker.
type Workflow ¶
type Workflow struct {
Name string `yaml:"name"`
Description string `yaml:"description"`
Instructions Instructions `yaml:"instructions"`
Stages []Stage `yaml:"stages"`
}
Workflow represents a workflow template.
func Load ¶
Load loads a workflow by name. First checks for local override in .subtask/workflows/<name>/WORKFLOW.yaml, then falls back to embedded default.
func LoadByName ¶
LoadByName loads a workflow by name. First checks for local override, then falls back to embedded default.
func LoadFromTask ¶
LoadFromTask loads a workflow from a task's folder (if WORKFLOW.yaml exists).
func (*Workflow) FirstStage ¶
FirstStage returns the first stage name.
func (*Workflow) FormatProgression ¶
FormatProgression returns a formatted stage progression string. Example: "plan → implement → review" with current stage marked.
func (*Workflow) NextStage ¶
NextStage returns the next stage name after current, or "" if current is last.
func (*Workflow) StageIndex ¶
StageIndex returns the index of a stage by name, or -1 if not found.
func (*Workflow) StageNames ¶
StageNames returns all stage names.