dist/claude/plugins/dev-flow/skills/fixing-code/SKILL.md
Fix code defects with a reproducible feedback loop, root-cause diagnosis, minimal patch, regression test, and clean verification. Use when debugging, diagnosing, or resolving lint/test/build failures. NOT for behavior-preserving refactors (use refactoring-code), test-suite cleanup without a production bug (use improving-tests), or code review findings without fixes (use reviewing-code).
npx skillsauth add alexei-led/claude-code-config fixing-codeInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Follow the base skill. This Claude overlay only defines tool use and execution details.
Fix the requested defect or failing gate one verified issue at a time. Do not expand to unrelated failures without asking. No guessing.
diagnose or investigate: use the hard-bug workflow with hypotheses and probes.team: spawn read-only analysis agents to challenge root cause before editing.Use TaskCreate and TaskUpdate when the fix has more than two steps:
Read, Grep, and Glob to inspect the exact failing path.AskUserQuestion if logs, payloads, access, repro steps, environment, or instrumentation approval are missing.Edit for existing files and Write only for new files or complete rewrites.Do not use destructive git commands. Do not use --no-verify.
Prefer configured project commands. Examples:
make lint
make test
go test ./...
ruff check .
pytest --tb=short
bun test
npm test
Use only commands supported by the repo and available tools. Browser-only debugging
belongs in browser-automation unless a cheaper CLI/unit signal exists.
Before editing, write 3-5 ranked falsifiable hypotheses. Probe one at a time. If
you add temporary logs, tag them with [DEBUG-<short-id>] and remove them before
final output.
If claude-mem is available, search for prior gotchas on failing files. Treat memory as a hint, not proof.
If team is set, agents analyze only. Ask for root cause, evidence, suggested fix,
priority, and confidence. Verify their claims before editing.
Use FIX COMPLETE for applied fixes:
FIX COMPLETE
============
Mode: standard | diagnose | team | diagnose+team
Issues found: X
Fixed: Y
Remaining: Z
Status: CLEAN | NEEDS ATTENTION
Root cause:
- <verified cause and evidence>
Changes:
- file:line — fix
Verification:
- <command> — pass/fail/skipped with reason
Use BLOCKED or Proposed Changes when tools, access, permission, or user input
prevents applying the fix. Include the exact missing artifact or permission needed.
Do not claim clean without a passing check or explicit skipped-check reason.
tools
Idiomatic shell development for POSIX sh, Bash, Zsh, Fish, hooks, CI shell steps, and scriptable CLI glue. Use when writing or changing `.sh`, `.bash`, `.zsh`, `.fish`, `.bats`, shell functions, shell pipelines, or command-runner recipes. Emphasizes portability, quoting, safe filesystem/process handling, non-TUI CLI tools, ShellCheck, shfmt, Bats, and ShellSpec. NOT for Python, TypeScript, Go, web code, or infrastructure operations.
tools
Use when planning, executing, checkpointing, finishing, or inspecting lightweight spec-driven work. Runs one task at a time using `.spec/` markdown files and the bundled `specctl` helper. NOT for broad product discovery beyond a short requirement interview.
testing
Author, inspect, troubleshoot, and review infrastructure across IaC, Kubernetes, cloud resources, containers, CI/CD, and Linux hosts. Use when changing Terraform/OpenTofu, Kubernetes, Helm, Kustomize, Dockerfiles, GitHub Actions, AWS, GCP, Cloud Run, BigQuery, IAM, logs, instances, or service health. NOT for deploy/apply/rollback workflows (see deploying-infra). NOT for shell scripts or generic command pipelines (see writing-shell).
development
Configure safe git workflow hygiene: pre-commit/pre-push hooks, Gitleaks secret scanning, .gitignore rules, local git config, and guardrails. Use when setting up git hooks, gitleaks/git leaks, staged pre-commit checks, pre-push validation, core.hooksPath, .gitignore, or git config best practices. NOT for creating commits (use committing-code), cleaning branches/worktrees (use cleanup-git), or creating worktrees (use using-git-worktrees).