daemon

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2026 License: AGPL-3.0 Imports: 12 Imported by: 0

Documentation

Overview

Package daemon implements the background auto-yes process.

When auto-yes is enabled, the TUI launches a detached child process (this package's RunDaemon entry point) that polls every tracked session.Instance on a configurable interval, uses the session/agent adapters to detect agent-specific prompts, and sends Enter to dismiss them. The daemon's PID is persisted to {configDir}/daemon.pid; the TUI kills and restarts the daemon on every launch to guarantee a clean state.

Per-tick work runs through a bounded goroutine pool ([daemonPool]) with a per-instance timeout ([tickInstanceTimeout]) so a single wedged tmux capture cannot stall the rest, and so persistent wedges surface as pool back-pressure rather than unbounded goroutine growth.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LaunchDaemon

func LaunchDaemon(wsCtx *config.WorkspaceContext) error

LaunchDaemon launches the daemon process. wsCtx must carry a resolved ConfigDir.

func RunDaemon

func RunDaemon(cfg *config.Config, wsCtx *config.WorkspaceContext) error

RunDaemon runs the daemon process which iterates over all sessions and runs AutoYes mode on them. It's expected that the main process kills the daemon when the main process starts. wsCtx must carry a resolved ConfigDir.

func StopDaemon

func StopDaemon(wsCtx *config.WorkspaceContext) error

StopDaemon attempts to stop a running daemon process if it exists. Returns no error if the daemon is not found (assumes the daemon does not exist). wsCtx must carry a resolved ConfigDir.

Types

This section is empty.

Jump to

Keyboard shortcuts

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