CLI commands
The most commonly used commands are listed below. Run any command with
-h to see all available flags.
| Command | Description |
|---|---|
erg start |
Start daemon using ~/.erg/daemon.yaml or current repo |
erg start --repo owner/repo |
Start daemon in the background for a specific repo |
erg start -f --repo owner/repo |
Start in foreground with live status display |
erg start --config config.yaml |
Start daemon watching multiple repos defined in a config file |
erg start --once --repo owner/repo |
Run one polling tick then exit (useful for debugging) |
erg stop |
Gracefully shut down the running daemon (auto-detects which one) |
erg status |
Show daemon status (auto-detects which daemon) |
erg status --tail |
Live split-screen log view — one column per active session |
erg configure |
Interactive wizard: checks prerequisites, sets up issue tracker,
and scaffolds .erg/workflow.yaml
|
erg clean |
Clear state, lock files, worktrees, auth files, MCP config files, session message files, and log files. Prompts for confirmation unless -y is passed. |
erg run --issue 42 |
Run the workflow for a single issue synchronously in the foreground, then exit |
erg run --issue ENG-123 --repo /path |
Run for a specific issue in a specific repo (accepts GitHub numbers, Asana GIDs, Linear identifiers) |
erg run --issue 42 --workflow .erg/custom.yaml |
Run with an explicit workflow config file |
erg stats |
Show aggregate session analytics: success rate, cost, time-to-merge, failure analysis, and feedback rounds |
erg stats --repo owner/repo |
Show stats for a specific repo |
erg run
Executes the full workflow for a single issue synchronously in the foreground. Fetches the issue from the configured provider, runs the workflow in a containerized Claude Code session, and exits when complete. Uses a distinct lock key so it won't conflict with a running daemon on the same repo.
Useful for testing workflows, one-off tasks, or CI/CD integration.
The --issue flag accepts the native ID format for the
configured provider: integer for GitHub, task GID for Asana, or issue
identifier (e.g. ENG-123) for Linear.
| Flag | Description |
|---|---|
--issue |
Issue ID to process (required) |
--repo |
Repo path (default: current git root) |
--workflow |
Path to workflow config file |
erg stats
Displays aggregate performance analytics from the daemon's persisted state. Stats reflect only items still in the state file — terminal items older than the configured max age (default 7 days) are pruned.
The report includes:
- Overview — total sessions, success rate, average cost per tracked session
- Time to merge — average, min, and max duration from creation to completion
- Token spend — top 10 sessions by cost with token counts
- Failure analysis — sessions grouped by step at failure, common error messages
- Feedback rounds — average and max feedback rounds across sessions
| Flag | Description |
|---|---|
--repo |
Repo to show stats for (owner/repo or filesystem path). Default: current repo. |