Files
dotfiles/git
David F GliddenandClaude Opus 5 448ce373ca [HARDENING] The hook now says when it did nothing (REVIEWED-105, PENDING-123)
Five disarming faults were measured silent at exit 0, indistinguishable from each
other and from a legitimate docs-only commit. All five now speak.

(b) A malformed declaration REFUSES rather than skips: no separator, empty pathspec,
empty command, or a pathspec git cannot resolve. The refusal names file, line number,
fault, the offending text, the expected form, and --no-verify — a gate that blocks
without saying why is replaced by habit within a week.

(e) instead of a flag, on the ruling's reasoning that a flag nobody sets is a
capability nobody has: the per-rule line prints in exactly the ambiguous case. A rule
ran, the existing lines already say so and nothing is added. No triggers file, this
block never runs, so no other repo gains noise. Rules declared and none matched is the
only case a reader cannot otherwise tell from a broken hook, so it is the only case
that gets a line. PRECOMMIT_VERBOSE adds per-rule detail for a suspect pathspec.

Two things the implementation found that the ruling did not specify. A triggers file
declaring no rules — comments-only or empty — left declared=0, so my first cut skipped
the report and those two rows stayed silent. That state is a disarmed hook wearing an
armed face: the file is present so the repo looks opted in, and every commit sails
through. It now reports rather than refuses, since refusing would block a legitimately
emptied file. And a rule that has never matched is honestly unknown, not passing and
not failing; the hook holds no history and does not imply one.

Matched-rule output is byte-identical to what REVIEWED-100's acceptance proved — the
split reproduces `IFS='|' read` exactly, including the retained leading space in the
display. One observable change: a docs-only commit still runs nothing but now says so.

Acceptance, all seven rows: control FIRED · typo REPORTED-no-match · no separator
REFUSED · empty command REFUSED · comments-only REPORTED-empty · empty file
REPORTED-empty · docs-only REPORTED-no-match. Red direction still refuses.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01A35wiD55yRHj5U1ECZAX4t
2026-08-08 18:06:52 +02:00
..