Sync
/flow-next:sync is the manual escape hatch for plan-sync.
/flow-next:work runs plan-sync automatically after every task when planSync.enabled is true. Use this skill when code changed outside the work loop — manual edits, an external PR, a worker that completed but did not trigger sync — and downstream task specs need to be re-checked against reality.
When to use it
Section titled “When to use it”- A spec’s later tasks reference paths or APIs that earlier tasks have since renamed.
- A teammate pushed changes that affect a task you have not started yet.
/flow-next:workran with plan-sync disabled and you want to catch up.- You want to preview drift before acting on it.
Inputs
Section titled “Inputs”/flow-next:sync <id> [--dry-run]<id> accepts:
- A spec ID (
fn-1-add-oauthor legacyfn-1). Syncs all tasks under the spec. - A task ID (
fn-1-add-oauth.2or legacyfn-1.2). Syncs that task and its downstream peers.
--dry-run shows what would change without writing.
What it does
Section titled “What it does”For each downstream task, sync compares the task spec against the current state of the codebase and the committed work of upstream tasks. When it finds drift — stale paths, renamed exports, signatures that no longer match — it surfaces the reason and proposes an update.
Plan-sync never silently rewrites a spec. The user always sees the diff and approves it before any write.
Outcomes
Section titled “Outcomes”| Result | Meaning |
|---|---|
clean | No drift. Downstream tasks still match reality. |
drift | Proposed updates with reasons. User approves or rejects per file. |
regenerate | Spec is too far gone to patch cleanly; offer to regenerate the affected tasks. |
What this is not
Section titled “What this is not”- Not a code change. Sync edits task specs, not implementation files.
- Not a replacement for
/flow-next:planwhen the spec is fundamentally out of date. If most tasks need regeneration, restart planning.
Next step
Section titled “Next step”/flow-next:work <next-ready-task>Or, if drift surfaced design-level issues, revisit the spec:
/flow-next:plan-review <spec-id>