Commands & CLI

iterate provides slash commands for Claude Code and CLI commands for direct terminal use. Both interact with the same daemon and worktree system.

Claude Code slash commands

After setup, these commands are available in your Claude Code session:

CommandWhat it does
/iterateSet up iterate in your project (run once). Detects framework, installs adapter, creates config, and registers the MCP server.
/iterate:prompt <text>Create multiple variations from a prompt. Each gets a worktree, represented by a tab on the toolbar overlay.
/iterate:goFetch all pending UI changes and implement them in the current iteration.
/iterate:keep <name>Pick the preferred iteration, merge it to the base branch, and clean up the rest.

Typical flow

1. Browse your app, use the overlay to annotate feedback
2. /iterate:go — agent reads pending changes, makes code changes
4. Dev server hot-reloads, you see results immediately
5. Repeat until satisfied
6. /iterate:keep v2 — merge the winner

CLI commands

These commands are available from your terminal after installing iterate:

CommandWhat it does
iterate initRegister an app (detects dev command, env files, package manager) and write .iterate/config.json. Re-run to register additional apps in a monorepo.
iterate doctorPreflight checks: config validity, daemon port availability, env file parsing, package managers, docker-compose hints
iterate serveLaunch the daemon (auto-picks a free port starting at 47100, writes .iterate/daemon.lock)
iterate branch <name> [--app <id>]Create a git worktree, install dependencies, start the chosen app's dev server on a unique port
iterate listShow all active iterations with their status, target app, and ports
iterate pick <name>Merge the named iteration to main, remove all other worktrees
iterate stopShut down the daemon and all running dev servers

Examples

# Start the daemon
iterate serve

# Create two parallel variations
iterate branch hero-minimal
iterate branch hero-bold

# Check what's running
iterate list

# Merge the winner
iterate pick hero-bold

# Clean up
iterate stop