← ClaudeAtlas

code-qualitylisted

Quality gate for a repo: one bun script behind git hooks (pre-commit, commit-msg, pre-push) and the Stop hooks of Claude Code, Codex and pi. Blocks test tampering, CRAP and complexity over the bar on changed functions, low diff coverage, new cycles, dead code, clones, secrets, vulnerable dependencies and AI attribution in commits. 12 languages, one .quality.toml per repo. Use when: quality gate, CRAP, complexity, ratchet, baseline, hotspots, dead code, import cycles, wire a repo into the gate, install quality hooks, .quality.toml, Stop hook for quality. Not for running ordinary tests, lint or typecheck.
smixs/code-quality-skill · ★ 1 · Code & Development · score 67
Install: claude install-skill smixs/code-quality-skill
# code-quality ## Overview One script, `scripts/quality.ts`, called by every entry point. Only deterministic checks decide the exit code. Old debt lives in a baseline and does not block; a new finding on a changed line does. Jev (a classifier) and other reviewers write notes only. | entry point | when | what runs | time | |---|---|---|---| | `pre-commit` | `git commit` | `check --staged` on the staged change | 10-20 s | | `commit-msg` | `git commit` | AI attribution, glossary words in the message | < 1 s | | `pre-push` | `git push` | tamper per pushed commit, tests touched by name and by import, diff coverage, Gitleaks, OSV audit | up to 1 min | | agent Stop | the agent ends a turn | `check` against `project.base`; red = one round of fixes | 10-20 s | | manual | before a large push, or to measure | full gate: tests with coverage, mean CRAP, worklist, hotspots | 3-6 min | CRAP needs fresh lcov (`.scratch/quality/lcov.info` with a matching fingerprint). Without it a fast entry point prints `tests: not run, no fresh lcov` and judges complexity only. A change of docs and config only (`.md`, `.toml`, `.json`, `.yml` outside `project.src`) prints `scope: docs-only` and skips the code checks. ## Commands ```bash Q=~/.claude/skills/code-quality/scripts/quality.ts bun $Q install-hooks <repo> # core.hooksPath for that repo only; repo hooks keep working bun $Q uninstall-hooks <repo> # put the previous core.hooksPath back bun $Q --repo <repo> --update-baseli