runner

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

Package runner provides parallel task execution for monox.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	WorkspaceRoot string
	Cache         cache.Cache
	Hasher        *cache.Hasher
	Parallelism   int
	DryRun        bool
	Verbose       bool
	FailFast      bool
}

Config holds runner configuration.

type Result

type Result struct {
	Stats    graph.TaskStats
	Duration time.Duration
	Errors   []error
}

Result holds the result of a task run.

type Runner

type Runner struct {
	// contains filtered or unexported fields
}

Runner executes tasks in parallel with caching support.

func NewRunner

func NewRunner(cfg Config) *Runner

NewRunner creates a new task runner.

func (*Runner) Events

func (r *Runner) Events() <-chan api.TaskEvent

Events returns the event channel.

func (*Runner) Run

func (r *Runner) Run(ctx context.Context, taskGraph *graph.TaskGraph) error

Run executes all tasks in the task graph.

func (*Runner) RunSingle

func (r *Runner) RunSingle(ctx context.Context, project *api.Project, task api.Task) error

RunSingle executes a single task without the full graph machinery.

func (*Runner) RunWithResult

func (r *Runner) RunWithResult(ctx context.Context, taskGraph *graph.TaskGraph) (*Result, error)

RunWithResult executes tasks and returns detailed results.

Jump to

Keyboard shortcuts

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