Documentation
¶
Index ¶
- Variables
- func HandleReportProgress(args []string) error
- func HandleYieldPendingQuestions(args []string) error
- func Logf(fmtStr string, args ...interface{})
- func ParseTimeoutDuration(s string) (time.Duration, error)
- func PromptContent(c Config) string
- func Run(ctx context.Context, c Config, opts Options) error
- func TestExported_NewSessionLogWriter() *sessionLogWriter
- func TestExported_autoDetectAgentRunner(c Config) (string, bool)
- func TestExported_formatEventLine(line string) string
- func TestExported_parseTimeoutDuration(s string) (time.Duration, error)
- func TestExported_runAgent(ctx context.Context, agentRunner, model, prompt, sessionID string, ...) (string, error)
- func TestExported_showStatus(c Config, opts Options) error
- func TestExported_traceSession(c Config, opts Options) error
- type Config
- type Options
Constants ¶
This section is empty.
Variables ¶
var TestProcessNameFunc func(pid int) string
TestProcessNameFunc is a test hook that, when non-nil, overrides the PID → process-name lookup used by autoDetectAgentRunner during Priority 4 (parent-process) detection. Tests set this to inject a fake process tree. The production getProcessName delegates to this hook before falling back to OS calls (ps on darwin, /proc on linux).
Functions ¶
func HandleReportProgress ¶
func ParseTimeoutDuration ¶ added in v0.0.23
ParseTimeoutDuration parses a duration string for the --timeout flag.
- Empty input defaults to 1 hour.
- Bare numbers (no suffix) are treated as seconds.
- Otherwise, parsed with time.ParseDuration.
- Whitespace is trimmed before parsing.
- Duration < 1 minute returns an error.
- 1m ≤ duration < 10m prints a warning to stderr.
func PromptContent ¶
func TestExported_NewSessionLogWriter ¶ added in v0.0.20
func TestExported_NewSessionLogWriter() *sessionLogWriter
TestExported_NewSessionLogWriter creates a sessionLogWriter for testing.
func TestExported_autoDetectAgentRunner ¶ added in v0.0.21
TestExported_autoDetectAgentRunner wraps the unexported autoDetectAgentRunner for doctest access.
func TestExported_formatEventLine ¶ added in v0.0.22
TestExported_formatEventLine wraps the unexported formatEventLine for doctest access.
func TestExported_parseTimeoutDuration ¶ added in v0.0.23
TestExported_parseTimeoutDuration wraps ParseTimeoutDuration for doctest access.
func TestExported_runAgent ¶ added in v0.0.20
func TestExported_runAgent(ctx context.Context, agentRunner, model, prompt, sessionID string, rawLog *sessionLogWriter) (string, error)
TestExported_runAgent wraps the unexported runAgent for doctest access.
func TestExported_showStatus ¶ added in v0.0.22
TestExported_showStatus wraps the unexported showStatus for doctest access.
func TestExported_traceSession ¶ added in v0.0.22
TestExported_traceSession wraps the unexported traceSession for doctest access.