/claude-dev-kit:diagnose [error description or file path]from claude-dev-kit
Analyzes a bug from error logs or reproduction steps, fixes it, and creates a GitHub Issue + PR using git worktrees for isolation.
Ships in claude-dev-kit. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Kit root: ${CLAUDE_PLUGIN_ROOT}
scripts/ dir): prefix every kit script command with it, e.g.
bash <kit-root>/scripts/checkpoint.sh …. Absolute paths also work from worktrees.${…} placeholder above → standalone layout: run commands as written.Run these checks silently at the start. Use results to adapt behavior:
[ -f issues.md ] — if true, this project uses the sprint system. Respect issue numbering and STATUS.md.[ -f docs/sprint_state.md ] — if true and Status shows running, a sprint is active. Be aware of parallel work in worktrees.[ -f docs/prd_digest.md ] — if true, read it for quick project context before starting.gh auth status before any GitHub operation.Every phase has a checkpoint. Run the verification command and check the exit code.
ADVISORY: line (advisory gate): report the gap, self-correct, continue.
Standard prefix:bash scripts/checkpoint.sh
Append --skill <name> --phase <phase> --issue <ID> for the specific check.
checkpoint.sh resolves the main repo root internally, so the command stays
a single prefix-matchable form (safe to allowlist as Bash(bash scripts/checkpoint.sh *)).
Pipeline skills operate in git worktrees to isolate changes from main.
WT="$(bash scripts/wt_setup.sh <branch>)" — creates the
worktree via scripts/worktree.sh create and writes .claude-kit/freeze-dir.txt
inside it in a single step.bash scripts/worktree.sh rootbash scripts/wt_cleanup.sh <branch> — cd's to main root
inside a subshell, then removes the worktree (never leaves CWD dangling).
All file operations happen inside $WT/. Shared files live on main only.Shared files (issues.md, STATUS.md, CHANGELOG.md) are managed on main only.
Always use registry_edit.sh for concurrent-safe writes — it resolves the
main repo root internally and delegates to flock_edit.sh:
bash scripts/registry_edit.sh issues.md -- bash -c '<update command>'
Never commit these files to feature branches.
Every phase in this skill that has a CHECKPOINT block must be verified. Run the verification command after completing each phase. Blocking gates exit non-zero on failure: STOP immediately, report, do NOT proceed. Advisory gates always exit 0 and print an ADVISORY: line on failure: report the gap, self-correct, then continue (ISSUE-031). Never skip running either tier.
Slug convention: After creating the worktree, store the branch slug (e.g., fix/bookmark-none-subscript) for use in checkpoint commands.
$ARGUMENTS is empty or blank, ask the user: "Please provide an error description, stack trace, or file path to diagnose."Steps:
gh authenticated (gh auth status).pytest to confirm no regressions. Suggest a regression test if none exists.WT="$(bash scripts/wt_setup.sh fix/<slug>)"
wt_setup.sh creates the worktree and writes the freeze marker inside
.claude-kit/freeze-dir.txt atomically. Apply the fix inside $WT/,
run tests from $WT/.CHECKPOINT — ADVISORY (report & continue) Run:
bash scripts/checkpoint.sh --skill diagnose --phase worktree --issue "$SLUG"Advisory: exits 0 even on failure, printing anADVISORY:line — report the gap, self-correct, then continue.
CHECKPOINT — MANDATORY — NEVER SKIP Run:
bash scripts/checkpoint.sh --skill diagnose --phase test --issue "$SLUG"If exit code ≠ 0: STOP immediately and report the failure. Do NOT proceed.
gh issue create --title "fix: <concise bug description>" --body "<body>"$WT/).CHECKPOINT — ADVISORY (report & continue) Run:
bash scripts/checkpoint.sh --skill diagnose --phase push --issue "$SLUG"Advisory: exits 0 even on failure, printing anADVISORY:line — report the gap, self-correct, then continue.
gh pr create --title "fix: <concise bug description>" --body "Closes #<issue_number>\n\n<details>"/review and /ship.If issues.md exists in the project root, register this work in the sprint ecosystem:
issues.md to find the next available ISSUE-NNN number.bash scripts/registry_edit.sh issues.md -- bash -c '<append issue entry>'
Issue fields:
<number><pr_url>If issues.md does not exist, skip this step silently.
gh auth status fails: stop and instruct the user to run gh auth login.bash scripts/wt_cleanup.sh <branch> for safe worktree removal —
the wrapper cd's to main root and removes the worktree in a single subshell.bash scripts/wt_cleanup.sh <branch>git push origin --delete <branch> (remote cleanup, if pushed)gh pr close <pr_number> then clean up worktree and branch as above.IMPORTANT: Never commit issues.md, STATUS.md, or CHANGELOG.md to the feature branch.
These are registry files managed only on main. Always use bash scripts/registry_edit.sh <file> -- bash -c '<update command>' — the wrapper resolves the main repo root internally.
except, empty catch).What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
23 skills in this plugin
/bizanalysisAnalyzes and critiques business viability. Use after /brainstorm and before /prd./brainstormExplores ideas and defines problems through free-form conversation. Use before /prd when direction is unclear./carefulActivates destructive command warnings for the current session. Use when working in sensitive environments./desktop-uiuxEstablishes a desktop design philosophy based on kickoff outputs, and generates a desktop design system/wireframes/Electron prototype. Recommended flow — /prd → /kickoff → /desktop-uiux/devopsSet up or update CI/CD pipelines, Dockerfiles, and deployment configs, then create a GH Issue + PR./figma2protoFetch Figma design via API and generate a complete design deliverable — prototype HTML, design system, design philosophy, interactions, and copy guide. Supports web, mobile, and desktop platforms.npx claudepluginhub pillip/claude-dev-kit --plugin claude-dev-kitOther plugins' skills for the same job