feat-exec
Use when the user wants to execute an existing pwdev-feat action plan — 'executar o plano user-crud', 'exec latest', 'rodar o plano', 'retomar a execução'. Dispatches the executor (subagent when the r
SKILL.mdplugins/pwdev-feat/skills/feat-exec/SKILL.md
GitHubExecute plan
You orchestrate; the executor implements. Dispatch mechanics per runtime and the inline
fallback: references/runtime.md. Prompts: references/spawn-contracts.md.
Arguments: <slug> or latest (default), optional --resume.
Procedure
- Language — resolve
lang(references/language.md). - Load —
python3 "<plugin-root>/scripts/feat_state.py" precheck <slug|latest>.PLAN_NOT_FOUND→ show how to create one (feat-feature / feat-backend / feat-frontend / feat-test / feat-review) and stop.already_executedwith noresume_step→ warn and ask whether to re-run.resume_steppresent → offer to resume from that step (implied by--resume).
- Lint —
python3 "<plugin-root>/scripts/plan_lint.py" <plan>. Errors → show them and stop (suggest fixing the plan with the skill that created it). Warnings → mention them. - Working tree —
dirty_planned_filesnot empty → list them and ask whether to proceed (the executor may commit them). Notebranch; on the default branch, ask before committing there. - Memory (optional, read-only) — if
.planning/memory/MEMORY.mdexists (curated by pwdev-code; never write there), pick ≤3 entries by keyword overlap with the plan (conventionfirst; 1 hop via[rel: ...]within the cap) into a RELEVANT MEMORY block. - Confirm with the human (gate):
📋 Executing plan: {plan} Type: {type} | Mode: {IMPLEMENT | REPORT (no commit)} | Runtime: {runtime} ({subagent|inline}) Objective: {objective} Files: {N} | Criteria: {N} | Steps: {N}{ | resuming at step n} Base commit: {sha} Proceed? (y/n) - Record (audit on):
sh "<plugin-root>/scripts/audit-log.sh" event exec "" started <plan> "<MODE>". Dispatch the executor with the executor prompt (full plan, MODE, SLUG, BASE COMMIT, PLUGIN ROOT, LANGUAGE, context documents for the plan type, RELEVANT MEMORY, andRESUME FROM STEP nwhen resuming). Model perreferences/model-profiles.md(keyfeat-executor). Record:sh "<plugin-root>/scripts/audit-log.sh" spawn exec "" pwdev-feat:executor <model|inherited|inline>. No subagent mechanism → followreferences/executor-contract.mdinline yourself. - React to the ≤10-line status (never open the reports unless the status requires it):
- Blocked-write fallback: if the reply carries
--- BEGIN FILE <path> ---blocks, write each content verbatim to its path (only paths under.planning/feat/features/{slug}/), and make sureplan.done.mdexists, rendered fromtemplates/plan.done.mdwith its<!-- feat-status: ... -->marker; note in the Deviations that the orchestrator persisted it. COMPLETE/CAVEATS→ step 9.STOPPED:<condition>→ present it and wait for the human.NEEDS_ADVICE→ at most ONE consultation per plan: dispatch the advisor with the advisor prompt (advice request + plan §1/§2/§7; keyfeat-advisor), logaudit-log.sh event exec "" advice_requestedand... advice_given, then re-dispatch the executor with the ADVICE block.NEEDS_ADVICEagain → present to the human and stop.FAILED→ re-dispatch ONCE with the retry block; fails again → stop and report both notes. Advice and retry counters are independent: at most 1 advice + 1 retry per plan.
- Blocked-write fallback: if the reply carries
- Record the outcome:
sh "<plugin-root>/scripts/audit-log.sh" event exec "" <completed|failed> <plan> "<STATUS>"(completedfor COMPLETE/CAVEATS,failedotherwise). Check the tree:git status --porcelain --untracked-files=all— report any change outside.planning/left by the run instead of hiding it. Present:✅ Plan {slug} executed — {COMPLETE | CAVEATS | FAILED} ({IMPLEMENT | REPORT}) Commit: {hash | none — findings at .planning/feat/features/{slug}/{review.md | test-audit.md}} Report: .planning/feat/features/{slug}/plan.done.md 👉 Next: feat-review {base_commit}..HEAD (IMPLEMENT only)
Prohibitions
- Never implement code yourself while a subagent mechanism is available — dispatch the executor.
- Never execute without the human's confirmation at step 6.
- Never commit in REPORT mode.
- Never paste
plan.done.mdor the findings file into your context — status lines only (the blocked-write fallback is written straight to disk, not summarized).
Language: resolve lang per references/language.md before any human-facing output. Safety: never read or expose .env* (except .env.example/.template/.sample), keys, certificates or credentials — references/safety.md. Paths references/, scripts/, templates/, schemas/ are relative to the plugin root (references/runtime.md).