verify

package
v0.4.9 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2026 License: MIT Imports: 7 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package verify executes verification steps defined in task frontmatter.

It runs bash commands and assertion checks with configurable timeouts and dry-run support, capturing output and exit codes.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Options

type Options struct {
	ProjectRoot string
	DryRun      bool
	FailFast    bool
	Timeout     time.Duration
	Verbose     bool
	LogFunc     func(format string, args ...any) // called before each step
}

Options configures verify execution.

type Result

type Result struct {
	Steps   []StepResult `json:"steps"`
	Passed  int          `json:"passed"`
	Failed  int          `json:"failed"`
	Pending int          `json:"pending"`
	Skipped int          `json:"skipped"`
}

Result holds the aggregate outcome of all verify steps.

func Run

func Run(steps []model.VerifyStep, opts Options) *Result

Run executes the given verify steps and returns the aggregate result.

func (*Result) HasFailures

func (r *Result) HasFailures() bool

HasFailures returns true if any bash step failed.

type StepResult

type StepResult struct {
	Index    int        `json:"index"`
	Type     string     `json:"type"`
	Status   StepStatus `json:"status"`
	Command  string     `json:"command,omitempty"`
	Dir      string     `json:"dir,omitempty"`
	Check    string     `json:"check,omitempty"`
	Stdout   string     `json:"stdout,omitempty"`
	Stderr   string     `json:"stderr,omitempty"`
	ExitCode int        `json:"exit_code,omitempty"`
	Duration string     `json:"duration,omitempty"`
	Warning  string     `json:"warning,omitempty"`
}

StepResult holds the outcome of a single verify step.

type StepStatus

type StepStatus string

StepStatus represents the outcome of a single verification step.

const (
	StatusPass    StepStatus = "pass"
	StatusFail    StepStatus = "fail"
	StatusPending StepStatus = "pending"
	StatusSkip    StepStatus = "skip"
)

Jump to

Keyboard shortcuts

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