Documentation
¶
Overview ¶
Package task manages task file CRUD and state machine transitions. Task files are markdown with YAML frontmatter stored under gtms/tasks/{status}/.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ValidStatuses = []string{"pending", "in-progress", "in-review", "complete", "error"}
ValidStatuses lists all valid task status values.
Functions ¶
Types ¶
type TaskFile ¶
type TaskFile struct {
ID string `yaml:"id"`
Type string `yaml:"type"` // create, automate, execute
Target string `yaml:"target"` // requirement ID or test case ID
Adapter string `yaml:"adapter"`
Status string `yaml:"status"` // pending, in-progress, in-review, complete, error
Created string `yaml:"created"` // ISO 8601
Branch string `yaml:"branch"`
Error string `yaml:"error,omitempty"`
Reference string `yaml:"reference,omitempty"` // create: --reference flag value; automate: test case source path
Framework string `yaml:"framework,omitempty"` // automate only
Environment string `yaml:"environment,omitempty"` // ENH-125: target environment (--env flag); rides task → record
ExecutedBy string `yaml:"executed_by,omitempty"` // ENH-125: resolved identity (--executed-by | env var | git user.name); rides task → record
}
TaskFile represents a GTMS task file with YAML frontmatter.
func FindByTarget ¶
FindByTarget finds a task by type and target across the given statuses. If no statuses are specified, checks pending and in-progress.
func List ¶
List returns all task files matching the given statuses. If no statuses are specified, all statuses are scanned.
Click to show internal directories.
Click to hide internal directories.