spawn

package
v0.11.1 Latest Latest
Warning

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

Go to latest
Published: Sep 23, 2026 License: MIT Imports: 2 Imported by: 0 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 spawn provides the Spawner interface used by both `entire review` and `entire investigate` to start an agent process non-interactively.

The interface is intentionally env-contract-agnostic: callers compose their own ENTIRE_REVIEW_* or ENTIRE_INVESTIGATE_* env via review.AppendReviewEnv or investigate.AppendInvestigateEnv before calling BuildCmd. Spawners only own the agent-specific argv shape and stdin wiring; they do not append review/investigate env.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Spawner

type Spawner interface {
	// Name returns the agent's stable registry name (e.g. "claude-code").
	Name() string

	// BuildCmd constructs the *exec.Cmd to spawn the agent.
	//   - env: the full process environment to set on cmd.Env (the caller has
	//     already appended ENTIRE_REVIEW_* or ENTIRE_INVESTIGATE_* values
	//     and stripped any stale entries before calling).
	//   - prompt: the composed prompt string. The spawner decides whether
	//     this goes via argv or stdin per the agent's CLI shape.
	BuildCmd(ctx context.Context, env []string, prompt string) *exec.Cmd
}

Spawner builds *exec.Cmd values for a specific agent in non-interactive, review/investigate mode. The returned Cmd MUST NOT be started yet — callers may attach pipes, modify env, etc., before invoking Start.

Jump to

Keyboard shortcuts

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