Phase: 3 — Code
Usage: /flow-code, /flow-code --auto, /flow-code --manual, or /flow-code --continue-step
Executes the approved plan one task at a time. Each task goes through
a full TDD cycle, user diff review, bin/flow ci gate, and commit before
the next task begins.
Each skill invocation executes exactly one task. After committing, the
skill self-invokes (--continue-step) to handle the next task in a
fresh invocation. The code_task field in the state file tracks progress
and is validated to increment by exactly 1 — preventing task batching.
For the current task:
bin/flow ci green (required)/flow-commit for this taskWhen tasks form a circular CI dependency (e.g., adding a new CI check and
fixing its violations in the same PR), no intermediate state can pass
bin/flow ci independently. The plan marks these tasks as an atomic
group with the reason they cannot be committed individually.
All tasks in the group are executed sequentially — each gets a full TDD
cycle and its own code_task increment — but bin/flow ci and commit
happen once after the last task. The code_task counter still increments
by exactly 1 per task; only the commit is deferred.
Architecture checks are defined by the framework instructions in the skill. Each framework enforces its own rules for reading code before writing, using test infrastructure correctly, and following framework conventions.
If a test fails during the CI gate but passes on retry without code changes,
it is flagged as flaky. A “Flaky Test” issue is filed via bin/flow issue
with reproduction data and recorded in the state file via bin/flow add-issue.
The task continues after filing — flaky tests do not block progress.
bin/flow ci — full suite, must be greencoverage/uncovered.txt must be emptyMode is configurable via .flow.json (default: manual). In auto mode, streamline is active from task 1 (skip per-task approval, still show diffs) and the phase transition advances to Code Review without asking.
bin/flow ci must be green before every commit