| name | feature-next |
| description | Implements a single task following the next → implement → check → done workflow with TDD support. Use when working on one specific task, implementing a single feature from the backlog, or following TDD red-green-refactor cycle. Triggers on 'next task', 'next feature', 'implement feature', 'work on feature', 'single task mode', 'what should I work on'. |
| allowed-tools | ["Bash","Read","Glob","Grep","Write","Edit"] |
| user-invocable | true |
Task Next
One command: agent-foreman next
⚠️ STRICT WORKFLOW - NO IMPROVISATION
You MUST follow this exact sequence. Do NOT skip or reorder steps.
next → implement → check → done
| ❌ FORBIDDEN | ✅ REQUIRED |
|---|
Skip check step | Run agent-foreman check before done |
| Go straight to implementation | Run agent-foreman next first |
| Invent extra steps | Use only the 4 steps above |
⛔ CLI-ONLY ENFORCEMENT
NEVER bypass CLI for workflow decisions:
| ❌ FORBIDDEN | ✅ REQUIRED |
|---|
Read ai/tasks/index.json to select task | Use agent-foreman next |
Read index.json to check status | Use agent-foreman status |
Read index.json for TDD mode | Check CLI output for !!! TDD ENFORCEMENT ACTIVE !!! |
| Edit task files to change status | Use agent-foreman done/fail |
Allowed: Reading task .md files for acceptance criteria AFTER running agent-foreman next.
Quick Start
agent-foreman next
agent-foreman next auth.login
Workflow
next → implement → check → done
agent-foreman next
agent-foreman check <id>
agent-foreman done <id>
Check TDD Mode First
Look for "!!! TDD ENFORCEMENT ACTIVE !!!" in agent-foreman next output.
TDD Workflow (when strict mode active)
agent-foreman next <task_id>
agent-foreman check <task_id>
agent-foreman done <task_id>
CRITICAL: DO NOT write implementation code before tests exist in strict TDD mode!
Priority Order
needs_review → may be broken
failing → not implemented
- Lower
priority number → higher priority (0 is highest)
⚠️ BREAKDOWN → VALIDATE → IMPLEMENT Workflow
When next shows "VALIDATION PHASE REMINDER":
agent-foreman validate
agent-foreman next
ALWAYS run done after completing each task (including BREAKDOWN tasks).
Options
| Flag | Effect |
|---|
--check | Run tests before showing task |
--dry-run | Preview without changes |
--json | Output as JSON for scripting |
--quiet | Suppress decorative output |
--allow-dirty | Allow with uncommitted changes |
--refresh-guidance | Force regenerate TDD guidance |
Complete Options
agent-foreman done <id>
agent-foreman done <id> --full
agent-foreman done <id> --skip-e2e
agent-foreman done <id> --no-commit