con un clic
cancel
Use when stopping an active curdx-flow execution loop or removing spec state.
Instalar con Codex o Claude Copia este prompt, pégalo en Codex, Claude u otro asistente, y deja que revise la página de la skill y la instale por ti.
Menú
Use when stopping an active curdx-flow execution loop or removing spec state.
Instalar con Codex o Claude Copia este prompt, pégalo en Codex, Claude u otro asistente, y deja que revise la página de la skill y la instale por ti.
Basado en la clasificación ocupacional SOC
Use when a spec has tasks.md and should enter autonomous task execution.
Use when starting curdx-flow, creating a spec, resuming work, or routing intent.
Use when handling curdx-flow flags, state files, delegation, execution loops, or skill entrypoint rules.
Use when curdx-flow needs user decisions after codebase facts are discovered.
Use when a spec has design.md and needs implementation tasks.
Use when showing curdx-flow slash skills, options, workflow, or troubleshooting.
| name | cancel |
| description | Use when stopping an active curdx-flow execution loop or removing spec state. |
| argument-hint | [spec-name-or-path] |
| allowed-tools | Read Bash Agent AskUserQuestion |
| disable-model-invocation | true |
You are canceling the active execution loop, cleaning up state files, and removing the spec directory.
This is a destructive operation. You MUST get explicit user confirmation via AskUserQuestion before deleting anything.
This command uses the plugin runtime for multi-root spec discovery:
curdx-flow specs resolve [name-or-path]
curdx-flow specs find <name>
$ARGUMENTS contains input:
./ or /: treat as full path, validate it existscurdx-flow specs find "$input" to searchcurdx-flow specs resolve to get active spec path from .current-specIf spec name exists in multiple roots (exit code 2 from find):
Multiple specs named '$name' found:
1. ./specs/$name
2. ./packages/api/specs/$name
Specify: /curdx-flow:cancel ./packages/api/specs/$name
Do NOT automatically select one. User must specify the full path.
$spec_path/.curdx-state.json exists (where $spec_path is the resolved full path)Before asking the user to confirm, gather a short summary so the prompt is informative:
# Count tracked artifacts and any modified files inside the spec dir
find "$spec_path" -maxdepth 2 -type f -name '*.md' | wc -l # artifact count
find "$spec_path" -type f | wc -l # total file count
If .curdx-state.json exists, capture:
phasetaskIndex / totalTasksglobalIterationUse AskUserQuestion with a single question containing:
Permanently delete spec '$spec_name' at '$spec_path'? This removes the spec directory and all its files. This cannot be undone.Confirm deleteDelete — proceed with full cleanup. Include in the description: phase=<phase>, progress=<taskIndex>/<totalTasks>, files=<total file count>.Cancel — abort, change nothing. Description: Keep the spec directory and state file intact.If the user picks Cancel (or any "Other" answer that isn't a clear confirmation), output:
Cancellation aborted. Nothing was deleted.
Spec preserved at: $spec_path
and STOP. Do not run any rm command.
Only proceed to the Cleanup section if the user explicitly chose Delete.
After confirmation:
Delete state file:
rm -f "$spec_path/.curdx-state.json"
Remove spec directory:
rm -rf "$spec_path"
Clear current spec marker:
rm -f ./specs/.current-spec
Update Spec Index (removes deleted spec from index):
node "${CLAUDE_PLUGIN_ROOT}/hooks/scripts/update-spec-index.mjs" --quiet
Quote every $spec_path use in the rm commands. Never run rm -rf against an unquoted variable or a path you have not just confirmed with the user.
Canceled execution for spec: $spec_name
Location: $spec_path
State before cancellation:
- Phase: <phase>
- Progress: <taskIndex>/<totalTasks> tasks
- Iterations: <globalIteration>
Cleanup:
- [x] Removed .curdx-state.json
- [x] Removed spec directory ($spec_path)
- [x] Cleared current spec marker
The spec and all its files have been permanently removed.
To start a new spec:
- Run /curdx-flow:new <name>
- Or /curdx-flow:start <name> <goal>
If there's no .curdx-state.json but the spec directory exists, still confirm with the user first (same AskUserQuestion, mentioning that there's no active state — only the directory). On Delete, run the same cleanup and report:
No active execution loop found for spec: $spec_name
Location: $spec_path
Cleanup:
- [x] Removed spec directory ($spec_path)
- [x] Cleared current spec marker
The spec has been removed.
To start a new spec:
- Run /curdx-flow:new <name>
- Or /curdx-flow:start <name> <goal>