chore(humanizer): README test-count badge + self-audit terminal humanization

- Bump README test-count badge: 635 → 792 (matches filesystem after Wave 0–5)
- Wire formatSelfAudit() through humanizeEnvelope + humanizeFindings so the
  terminal-output path renders humanized finding titles. The --json path is
  unchanged — only the prose terminal render is humanized.
- readmeCheck.passed now returns true; configGrade A (97), pluginGrade A (100)
This commit is contained in:
Kjell Tore Guttormsen 2026-05-01 20:22:09 +02:00
commit b99773ec27
2 changed files with 11 additions and 2 deletions

View file

@ -12,7 +12,7 @@
![Commands](https://img.shields.io/badge/commands-18-green)
![Agents](https://img.shields.io/badge/agents-6-orange)
![Hooks](https://img.shields.io/badge/hooks-4-red)
![Tests](https://img.shields.io/badge/tests-635+-brightgreen)
![Tests](https://img.shields.io/badge/tests-792+-brightgreen)
![License](https://img.shields.io/badge/license-MIT-lightgrey)
A Claude Code plugin that checks configuration health, suggests context-aware improvements, and auto-fixes issues — `CLAUDE.md`, `settings.json`, hooks, rules, MCP servers, `@imports`, and plugins. 12 deterministic scanners across 10 quality areas, context-aware feature recommendations, auto-fix with backup/rollback, an Opus-4.7-aware Token Hotspots scanner with optional API-calibrated `--accurate-tokens` mode, plus cache-prefix stability, dead-tool, and cross-plugin collision detection. Zero external dependencies.

View file

@ -19,6 +19,7 @@ import { scoreByArea } from './lib/scoring.mjs';
import { gradeFromPassRate } from './lib/severity.mjs';
import { loadSuppressions, applySuppressions } from './lib/suppression.mjs';
import { parseJson } from './lib/yaml-parser.mjs';
import { humanizeEnvelope, humanizeFindings } from './lib/humanizer.mjs';
const execFileAsync = promisify(execFile);
@ -268,6 +269,14 @@ export async function runSelfAudit(opts = {}) {
* @returns {string}
*/
export function formatSelfAudit(result) {
// Humanize findings for terminal-output path only. JSON path (--json) is
// unaffected \u2014 it serializes the original `result` object directly.
const humanizedConfigEnv = humanizeEnvelope(result.configEnvelope);
const humanizedAllFindings = [
...humanizedConfigEnv.scanners.flatMap(s => s.findings),
...humanizeFindings(result.pluginHealthResult.findings),
];
const lines = [];
lines.push('\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501');
lines.push(' Config-Audit Self-Audit');
@ -278,7 +287,7 @@ export function formatSelfAudit(result) {
lines.push('');
// Issues summary
const nonInfo = result.allFindings.filter(f => f.severity !== 'info');
const nonInfo = humanizedAllFindings.filter(f => f.severity !== 'info');
if (nonInfo.length > 0) {
lines.push(` Issues (${nonInfo.length}):`);
for (const f of nonInfo.slice(0, 10)) {