/ct:fix-loopfrom ct
Iteratively reviews code for critical issues, fixes them, and runs tests, repeating until clean or max iterations (5) reached. Useful for bulk bug fixing and code cleanup.
Ships in ct. 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.
None: SKILL.md is the whole skill.
Autonomous review-fix cycle that iterates until all critical issues are resolved.
The value of this skill is that it separates finding problems from fixing them. The code-reviewer agent operates read-only with a disconfirmation mindset — it actively looks for flaws. The fixer agent then applies minimal, targeted changes. This separation prevents the common failure mode where a fixer rationalises away problems it finds in code it's about to change.
One of:
Determine which files to review, in priority order:
git diff --name-only (unstaged) + git diff --name-only --staged (staged)git diff --name-only HEAD~3Run the project's test suite before making any changes.
Auto-detect the test command by inspecting the project for build/config files. If the detected command fails on first run, ask the user for the correct test command. Once confirmed, write the command to the CLAUDE.md file for the project.
Record the result — this is needed later to distinguish pre-existing failures from regressions introduced by fixes.
Set iteration = 1 and scope = <initial files>.
HARD GATE - Iteration Cap:
→ iteration reaches 6 → STOP loop unconditionally. Report final status. Do not allow "just one more cycle."
LOOP while iteration <= 5:
Five iterations is the cap because experience shows that if critical findings persist beyond 3-4 cycles, the remaining issues typically need human judgement rather than automated fixing.
REVIEW (iteration N) — Announce: Review iteration N/5
code-reviewer agent with scope as its inputTRIAGE → Report received → Extract only 🔴 Critical findings. Discard all warnings and suggestions. → Zero critical findings? → Break loop, report clean. → N critical findings? → List for visibility, pass to fixer. Only critical findings are actioned because warnings and suggestions are judgement calls best left to the author.
FIX (iteration N) — Announce: Fix iteration N/5 — addressing N critical issue(s)
fixer agent, passing it:
NARROW SCOPE — Set scope to the files listed in the fixer's "Files Modified" output
INCREMENT — iteration += 1
END LOOP
Announce: Fix loop complete
# Fix Loop Report
## Iterations: N/5
## Resolved (Critical)
- [file:line] [issue] — fixed in iteration N
## Remaining (Critical)
- [file:line] [issue] — reason not fixed
## Noted (Warning / Suggestion)
- [file:line] [issue] — from iteration N (not actioned)
## Test Status
[Compare against baseline from Step 2. Report regressions vs pre-existing failures.]
Ask the user: Commit these changes?
If yes, use /commit or create a conventional commit directly.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
38 skills in this plugin
/argocdDeep ArgoCD operational intuition — sync waves and hook lifecycle, ApplicationSet generators, Sync vs Health, drift root causes, sync options, AppProject constraints, rollback, multi-cluster. Load for sync ordering, hook design, drift diagnosis, generator selection, rollback planning, or multi-cluster registration. Skip for "what is GitOps", install walkthroughs, or basic Application YAML. Triggers on: "sync wave", "presync hook", "syncfail", "applicationset generator", "matrix generator", "hpa replicas drift", "ignoreDifferences", "ServerSideApply", "Replace=true", "self-heal", "app-of-apps cascade".
/audit-skillsAudit installed skills for redundancy with built-in model knowledge. Use when asked to "audit skills", "review my skills", "check skill redundancy", "which skills are useful", "clean up skills", or "are my skills teaching you anything new"./bash-hardeningDeep bash correctness — `set -euo pipefail` traps, IFS/word-splitting, trap inheritance, process substitution, array gotchas, version-gated features, ShellCheck "looks right but isn't" patterns. Load when writing or hardening non-trivial bash scripts (installers, CI, unattended ops). Skip for basic if/while/for, one-shot interactive commands, or zsh/fish/POSIX-sh work. Triggers on: "set -e not triggering", "pipefail", "trap ERR", "PIPESTATUS", "macOS bash 3.2", "shellcheck SC2086", "harden bash script", "robust bash".
/bugmagnetDiscover edge cases and test coverage gaps through systematic analysis. Use when analysing TEST coverage, hunting for edge cases, or when code-reviewer identifies test gaps. Triggers on "find holes in my tests", "what could go wrong", "is this well tested", "what edge cases am I missing". When to pick bugmagnet vs alternatives: - find-bugs → branch-diff bug scan (uses git diff, scoped to recent changes) - security-review → OWASP-categorised vulnerability audit - code-review → PR-style review with comment threads - ct:bugmagnet → test-gap edge-case discovery (THIS one) If the question is "are my TESTS missing cases?", use bugmagnet. Otherwise pick one of the three above.
/ci-failure-triageDiagnose a failing GitHub Actions run. Fetch the failing job's step logs, correlate with recent commits, and produce a ranked top-3 root-cause hypothesis plus a minimal fix proposal. Use when the user says "CI is failing", "why did the build break", "triage this GHA failure", "workflow failed", "what broke CI", or pastes a `gh run` URL / run ID. Read-only — does NOT apply fixes, restart the run, or tail logs. For workflow-file security audits use gha-security-review; for local test failures use fix-loop.
/c-languageDeep C operational intuition — undefined behavior, sanitizers (ASan/UBSan/TSan/MSan), hardening flags, atomics/memory ordering, fuzzing, ABI quirks. Load when diagnosing UB, configuring sanitizers or hardened builds, investigating data races, or debugging alignment/atomics. Skip for ordinary C coding, malloc/free, or syntax help. Triggers on: "undefined behavior", "strict aliasing", "AddressSanitizer", "UBSan", "Valgrind", "use-after-free", "_FORTIFY_SOURCE", "memory_order", "libFuzzer", "ABI".
npx claudepluginhub pvillega/claude-templates --plugin ctOther plugins' skills for the same job