plumbbob 0.6.6 → 0.8.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (109) hide show
  1. package/.claude-plugin/plugin.json +2 -2
  2. package/README.md +24 -7
  3. package/dist/cli-core.js +7 -2
  4. package/dist/lib/buildlog.js +5 -2
  5. package/dist/lib/check.js +33 -1
  6. package/dist/lib/git.js +17 -0
  7. package/dist/lib/latch.js +97 -0
  8. package/dist/lib/orient.js +24 -0
  9. package/dist/lib/settings.js +3 -9
  10. package/dist/lib/sidecar.js +169 -18
  11. package/dist/verbs/build.js +5 -1
  12. package/dist/verbs/checkpoint.js +51 -2
  13. package/dist/verbs/doctor.js +40 -5
  14. package/dist/verbs/finish.js +61 -11
  15. package/dist/verbs/revert.js +19 -1
  16. package/dist/verbs/start.js +38 -7
  17. package/dist/verbs/status.js +10 -3
  18. package/dist/verbs/turn.js +106 -0
  19. package/dist/verbs/use.js +4 -5
  20. package/hooks/hooks.json +15 -0
  21. package/hooks/post-edit.sh +7 -7
  22. package/hooks/pre-bash-commit.sh +68 -0
  23. package/node_modules/checkride/CHANGELOG.md +111 -0
  24. package/node_modules/checkride/README.md +185 -20
  25. package/node_modules/checkride/dist/adapters.d.ts +9 -4
  26. package/node_modules/checkride/dist/adapters.d.ts.map +1 -1
  27. package/node_modules/checkride/dist/adapters.js +62 -2
  28. package/node_modules/checkride/dist/adapters.js.map +1 -1
  29. package/node_modules/checkride/dist/agent-setup/hook.d.ts +63 -0
  30. package/node_modules/checkride/dist/agent-setup/hook.d.ts.map +1 -0
  31. package/node_modules/checkride/dist/agent-setup/hook.js +92 -0
  32. package/node_modules/checkride/dist/agent-setup/hook.js.map +1 -0
  33. package/node_modules/checkride/dist/agent-setup/index.d.ts +8 -0
  34. package/node_modules/checkride/dist/agent-setup/index.d.ts.map +1 -0
  35. package/node_modules/checkride/dist/agent-setup/index.js +7 -0
  36. package/node_modules/checkride/dist/agent-setup/index.js.map +1 -0
  37. package/node_modules/checkride/dist/atomic.d.ts +13 -0
  38. package/node_modules/checkride/dist/atomic.d.ts.map +1 -0
  39. package/node_modules/checkride/dist/atomic.js +24 -0
  40. package/node_modules/checkride/dist/atomic.js.map +1 -0
  41. package/node_modules/checkride/dist/baseline/command.d.ts +42 -0
  42. package/node_modules/checkride/dist/baseline/command.d.ts.map +1 -0
  43. package/node_modules/checkride/dist/baseline/command.js +58 -0
  44. package/node_modules/checkride/dist/baseline/command.js.map +1 -0
  45. package/node_modules/checkride/dist/baseline/fingerprint.d.ts +41 -0
  46. package/node_modules/checkride/dist/baseline/fingerprint.d.ts.map +1 -0
  47. package/node_modules/checkride/dist/baseline/fingerprint.js +119 -0
  48. package/node_modules/checkride/dist/baseline/fingerprint.js.map +1 -0
  49. package/node_modules/checkride/dist/baseline/index.d.ts +13 -0
  50. package/node_modules/checkride/dist/baseline/index.d.ts.map +1 -0
  51. package/node_modules/checkride/dist/baseline/index.js +10 -0
  52. package/node_modules/checkride/dist/baseline/index.js.map +1 -0
  53. package/node_modules/checkride/dist/baseline/store.d.ts +67 -0
  54. package/node_modules/checkride/dist/baseline/store.d.ts.map +1 -0
  55. package/node_modules/checkride/dist/baseline/store.js +110 -0
  56. package/node_modules/checkride/dist/baseline/store.js.map +1 -0
  57. package/node_modules/checkride/dist/cli.d.ts.map +1 -1
  58. package/node_modules/checkride/dist/cli.js +37 -3
  59. package/node_modules/checkride/dist/cli.js.map +1 -1
  60. package/node_modules/checkride/dist/config.d.ts +43 -3
  61. package/node_modules/checkride/dist/config.d.ts.map +1 -1
  62. package/node_modules/checkride/dist/config.js +95 -22
  63. package/node_modules/checkride/dist/config.js.map +1 -1
  64. package/node_modules/checkride/dist/digest/digest.d.ts +52 -0
  65. package/node_modules/checkride/dist/digest/digest.d.ts.map +1 -0
  66. package/node_modules/checkride/dist/digest/digest.js +147 -0
  67. package/node_modules/checkride/dist/digest/digest.js.map +1 -0
  68. package/node_modules/checkride/dist/digest/index.d.ts +8 -0
  69. package/node_modules/checkride/dist/digest/index.d.ts.map +1 -0
  70. package/node_modules/checkride/dist/digest/index.js +7 -0
  71. package/node_modules/checkride/dist/digest/index.js.map +1 -0
  72. package/node_modules/checkride/dist/doctor.d.ts +4 -0
  73. package/node_modules/checkride/dist/doctor.d.ts.map +1 -1
  74. package/node_modules/checkride/dist/doctor.js +33 -10
  75. package/node_modules/checkride/dist/doctor.js.map +1 -1
  76. package/node_modules/checkride/dist/index.d.ts +1 -1
  77. package/node_modules/checkride/dist/index.d.ts.map +1 -1
  78. package/node_modules/checkride/dist/index.js +1 -1
  79. package/node_modules/checkride/dist/index.js.map +1 -1
  80. package/node_modules/checkride/dist/init.d.ts +38 -0
  81. package/node_modules/checkride/dist/init.d.ts.map +1 -1
  82. package/node_modules/checkride/dist/init.js +97 -8
  83. package/node_modules/checkride/dist/init.js.map +1 -1
  84. package/node_modules/checkride/dist/orchestrator.d.ts +58 -1
  85. package/node_modules/checkride/dist/orchestrator.d.ts.map +1 -1
  86. package/node_modules/checkride/dist/orchestrator.js +155 -27
  87. package/node_modules/checkride/dist/orchestrator.js.map +1 -1
  88. package/node_modules/checkride/dist/pm/detect.d.ts +21 -0
  89. package/node_modules/checkride/dist/pm/detect.d.ts.map +1 -0
  90. package/node_modules/checkride/dist/pm/detect.js +60 -0
  91. package/node_modules/checkride/dist/pm/detect.js.map +1 -0
  92. package/node_modules/checkride/dist/pm/index.d.ts +10 -0
  93. package/node_modules/checkride/dist/pm/index.d.ts.map +1 -0
  94. package/node_modules/checkride/dist/pm/index.js +9 -0
  95. package/node_modules/checkride/dist/pm/index.js.map +1 -0
  96. package/node_modules/checkride/dist/pm/translate.d.ts +28 -0
  97. package/node_modules/checkride/dist/pm/translate.d.ts.map +1 -0
  98. package/node_modules/checkride/dist/pm/translate.js +40 -0
  99. package/node_modules/checkride/dist/pm/translate.js.map +1 -0
  100. package/node_modules/checkride/package.json +20 -17
  101. package/node_modules/checkride/schema/checkride.config.schema.json +97 -0
  102. package/node_modules/checkride/schema/checkride.summary.schema.json +57 -0
  103. package/node_modules/checkride/templates/shared/cspell.json +1 -0
  104. package/node_modules/checkride/templates/shared/prettierrc.json +6 -0
  105. package/package.json +8 -4
  106. package/skills/pb-build/SKILL.md +31 -1
  107. package/skills/pb-finish/SKILL.md +2 -1
  108. package/skills/pb-plan/SKILL.md +17 -0
  109. package/skills/pb-verify/SKILL.md +32 -0
@@ -0,0 +1,68 @@
1
+ #!/bin/sh
2
+ # pre-bash-commit.sh — the git-commit ask-hook (D66). PreToolUse on Bash: when a
3
+ # step is in flight and the model reaches for a raw `git commit`, turn that commit
4
+ # into a permission *question*, never a wall. checkpoint owns the landing (the latch
5
+ # lives there); this only nudges the human to route through it. ALWAYS exits 0 and
6
+ # never `deny`s — the human decides, C5 stays intact (D66). `plumbbob checkpoint`'s
7
+ # own internal `git commit` spawn never passes through hooks, so nothing self-trips.
8
+
9
+ # The repo root is the nearest ancestor with an active session — `.plumbbob/STATE`,
10
+ # the sentinel `start` writes and `finish` removes. Present in both the tracked and
11
+ # the `--local` layout (post-edit.sh only fires when STATE is non-empty, i.e. a
12
+ # tracked build; this hook must guard `--local` steps too, so it probes existence).
13
+ find_root() {
14
+ d=$(pwd -P)
15
+ while [ -n "$d" ]; do
16
+ if [ -f "$d/.plumbbob/STATE" ]; then
17
+ printf '%s' "$d"
18
+ return 0
19
+ fi
20
+ [ "$d" = "/" ] && break
21
+ d=$(dirname "$d")
22
+ done
23
+ return 1
24
+ }
25
+
26
+ root=$(find_root) || exit 0 # no active session here: nothing to guard
27
+
28
+ # The in-flight signal is STEP (cleared when the step checkpoints): inside the
29
+ # active build's folder when STATE names one, else the flat sidecar STEP of the
30
+ # `--local` layout. STATE's content IS the cursor (D28) — read the first line, trim
31
+ # whitespace, and treat the legacy `active` sentinel (pre-STATE-cursor) as no cursor.
32
+ slug=$(head -n1 "$root/.plumbbob/STATE" 2>/dev/null | tr -d '[:space:]')
33
+ [ "$slug" = "active" ] && slug=""
34
+ if [ -n "$slug" ]; then
35
+ step_file="$root/.plumbbob/builds/$slug/STEP"
36
+ else
37
+ step_file="$root/.plumbbob/STEP"
38
+ fi
39
+ [ -f "$step_file" ] || exit 0 # no step in flight: silent
40
+
41
+ input=$(cat)
42
+ cmd=$(printf '%s' "$input" | jq -r '.tool_input.command // empty' 2>/dev/null)
43
+ [ -z "$cmd" ] && cmd=$(printf '%s' "$input" | sed -n 's/.*"command"[[:space:]]*:[[:space:]]*"\([^"]*\)".*/\1/p' | head -n1)
44
+ [ -z "$cmd" ] && exit 0
45
+
46
+ # A command *mentioning* "git commit" is prose, not a commit — a grep pattern, an
47
+ # echoed sentence, a checkpoint --body heredoc. Best-effort strip before matching:
48
+ # drop heredoc bodies (everything below the first `<<` line; the operator line
49
+ # itself still counts, so `git commit -F- <<MSG` is caught) and quoted string
50
+ # contents. A real commit that follows a heredoc body in the same command slips
51
+ # through unasked — acceptable for an affordance that never gates.
52
+ stripped=$(printf '%s\n' "$cmd" |
53
+ awk '{ print } /<</ { exit }' |
54
+ sed -e "s/'[^']*'//g" -e 's/"[^"]*"//g')
55
+
56
+ # Match a `git … commit` invocation: `git` as a command word (start or after a
57
+ # non-word char), then — without crossing a shell separator (`&& || ; |`) — the
58
+ # `commit` subcommand as a whole word. This clears `git status`/`git diff`/`git log`
59
+ # (no `commit` word) and `git log --grep=commit` (`=commit`, no space before it),
60
+ # while still catching `git -C path commit` and `git commit -m …`.
61
+ printf '%s' "$stripped" |
62
+ grep -Eq '(^|[^[:alnum:]_])git[[:space:]]+([^&|;]*[[:space:]])?commit([[:space:]]|$)' || exit 0
63
+
64
+ # A step is in flight and this is a raw commit: ask (never deny — the human decides).
65
+ # The reason is static, so a plain printf of the literal JSON needs no escaping.
66
+ printf '%s\n' '{"hookSpecificOutput": {"hookEventName": "PreToolUse", "permissionDecision": "ask", "permissionDecisionReason": "plumbbob: a step is in flight — checkpoint owns the landing. Approve only if you asked for this commit."}}'
67
+
68
+ exit 0
@@ -4,6 +4,114 @@ All notable changes to this project are documented here. The format is based on
4
4
  [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project
5
5
  adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [0.3.0] - 2026-07-10
8
+
9
+ ### Added
10
+
11
+ - **Vacuous-green signal.** `summary.json` gains a top-level `checks_run` count
12
+ of the checks that actually executed, so "green because everything passed" and
13
+ "green because nothing ran" are distinguishable by every consumer: `ok: true`
14
+ with `checks_run: 0` means nothing was verified. A zero-check run now prints a
15
+ loud warning naming why each slot sat out and how to enable it, and the new
16
+ `--strict` flag turns that case into exit 2 (for CI and commit-hook gates; the
17
+ default stays a warned exit 0 so exploring a fresh repo isn't punished).
18
+ `checks_run` is additive — `schema_version` is unchanged.
19
+ - **A frozen, tested contract.** `docs/contract.md` declares the surfaces
20
+ consumers may rely on — the exit-code taxonomy, the `summary.json`
21
+ additive-only discipline, the CLI flags, the programmatic exports, and the
22
+ pre-1.0 exact-pin policy — each locked by a new `test/contract/` suite that
23
+ fails the build on drift. The summary shape ships as a published JSON Schema
24
+ (`schema/checkride.summary.schema.json`).
25
+ - `DEFAULT_TIMEOUT_SECONDS` is now part of the public programmatic surface.
26
+ - New docs: a copy-paste CI guide (`docs/ci.md`), a reliability article
27
+ (`docs/reliability.md`), and `CONTRIBUTING.md` with the release ritual and
28
+ succession path.
29
+
30
+ ### Changed
31
+
32
+ - **Per-check timeouts are on by default** (600s; override per check or globally,
33
+ `0` to disable). A check that exceeds it is killed (SIGTERM → grace → SIGKILL)
34
+ and recorded as failed with a "timed out" note — a hung tool can no longer
35
+ hang the definition of done. Give long-running slots (`test`, `mutation`, …) a
36
+ higher cap or `0` on large repos.
37
+ - Run artifacts (`summary.json`, the raw slot files, the digest, the baseline)
38
+ are written atomically (temp file then rename), so a run interrupted mid-write
39
+ never leaves a consumer a half-written file to parse.
40
+
41
+ ### Fixed
42
+
43
+ - The supported Node floor is now stated consistently as `>=22.18` across the
44
+ docs; `docs/tools.md` and `docs/getting-started.md` previously claimed `>=24`,
45
+ contradicting `package.json` engines.
46
+
47
+ ### Internal
48
+
49
+ - CI runs the full suite across macOS and Linux at the Node floor (22.18.0) and
50
+ current (24), and the e2e suite exercises all four package managers
51
+ (pnpm/npm/yarn/bun) plus an interrupted-run case. Releases now publish with npm
52
+ provenance, and the README wears the Stryker mutation score.
53
+
54
+ ## [0.2.1] - 2026-07-08
55
+
56
+ ### Fixed
57
+
58
+ - Every `checkride init` scaffold shipped a `spell` check that failed out of the
59
+ box: the generated AGENTS.md contract stanza uses the word "baselined", but the
60
+ scaffolded `cspell.json` dictionary didn't include it, so a freshly generated
61
+ project's first `checkride` run exited non-zero.
62
+
63
+ ### Internal
64
+
65
+ - Added a fast local guard (`generated-spell.test.ts`) that runs cspell against an
66
+ in-process `init` scaffold for each shape, catching this class of drift in
67
+ `pnpm check` instead of only in the slower end-to-end suite.
68
+
69
+ ## [0.2.0] - 2026-07-08
70
+
71
+ ### Added
72
+
73
+ - **Baseline** — adopt checkride on an existing repo without turning it into a
74
+ cleanup project. `checkride baseline` records current diagnostics into a
75
+ committed `checkride.baseline.json`; a normal run then passes a slot as long as
76
+ only baselined findings remain, fails listing only genuinely new ones, and
77
+ *ratchets* the file smaller as findings are fixed — never larger, and never
78
+ pruned on a partial `--only`/`--skip`/`--changed` run. `checkride init
79
+ --baseline` grandfathers today's debt instead of disabling failing slots.
80
+ Grandfathered counts surface in `.check/summary.json` as an additive
81
+ `baselined` field.
82
+ - **Package-manager-agnostic runs** — checkride detects pnpm, npm, yarn, or bun
83
+ (from the lockfile or the `packageManager` field) and translates each tool
84
+ invocation accordingly; the default pnpm behavior is byte-identical to before.
85
+ `doctor` reports the detected manager. The `security` audit stays pnpm-only
86
+ until per-manager adapters land.
87
+ - **`checkride agent-setup`** plus an `init` Stop hook — both write an idempotent
88
+ Claude Code Stop hook to `.claude/settings.json` that runs the gate on the
89
+ *detected* package manager and blocks a stop while checks are red. `agent-setup`
90
+ also (re)writes the AGENTS.md contract stanza for a repo set up without a full
91
+ `init`. Both are opt-out with `--no-hook`.
92
+ - **`format` slot** (opt-in) — a blessed `prettier` adapter (with `biome` as an
93
+ alternate) that runs before `lint` and is wired into `checkride fix`. Excluded
94
+ from the default run so upgrading never turns a repo red; `init` can enable it
95
+ for greenfield projects. The `order: "first"` custom-check hatch still works for
96
+ bespoke formatters.
97
+ - **`publint` and `attw` slots** (opt-in) — library-publishing checks that make
98
+ "the published package is correct" part of the definition of done: `publint`
99
+ lints the `package.json` publishing surface, `attw` verifies types resolve
100
+ across module systems. Detect-gated so apps that never publish don't run them.
101
+ - **Config presets via `extends`** — `checkride.config.json` accepts `"extends":
102
+ "<package-or-path>"` (string or array) to inherit a shared base; local keys win,
103
+ and a missing or circular extend fails with a friendly message.
104
+ - **`--digest`** — writes a token-bounded Markdown excerpt of the failing slots to
105
+ `.check/digest.md`, each section pointing at the authoritative raw output, so
106
+ agents spend less context triaging failures on large repos. Absent on a green
107
+ run.
108
+ - **Custom-check `detect` field** — a custom check can declare `detect:
109
+ ["<file>"]` so a shared preset skips it when the file is absent and activates it
110
+ when present, keeping one config safe across heterogeneous repos.
111
+ - **Published JSON Schema** — `schema/checkride.config.schema.json` describes the
112
+ full config surface and ships in the package; `init` writes a version-pinned
113
+ `$schema` pointer into generated configs for editor validation.
114
+
7
115
  ## [0.1.6] - 2026-06-30
8
116
 
9
117
  ### Added
@@ -130,6 +238,9 @@ The first real release. (`0.0.0` was a name-claim placeholder.)
130
238
  - Flags: `--only`, `--skip`, `--bail`, `--json`, `--changed`, `--all`,
131
239
  `--include`.
132
240
 
241
+ [0.3.0]: https://www.npmjs.com/package/checkride/v/0.3.0
242
+ [0.2.1]: https://www.npmjs.com/package/checkride/v/0.2.1
243
+ [0.2.0]: https://www.npmjs.com/package/checkride/v/0.2.0
133
244
  [0.1.6]: https://www.npmjs.com/package/checkride/v/0.1.6
134
245
  [0.1.5]: https://www.npmjs.com/package/checkride/v/0.1.5
135
246
  [0.1.4]: https://www.npmjs.com/package/checkride/v/0.1.4
@@ -35,17 +35,28 @@ pnpm exec checkride init # set up a project (new or existing, auto-detected)
35
35
  ```
36
36
 
37
37
  `init` writes a `"check": "checkride"` alias, so daily usage is `pnpm check`
38
- regardless of the tool's name.
38
+ regardless of the tool's name. It also writes the agent contract: an AGENTS.md
39
+ stanza (the "exit 0 = done" rule) and a Claude Code **Stop hook** in
40
+ `.claude/settings.json` that blocks an agent from finishing while the pipeline is
41
+ red. The hook uses your detected package manager (`pnpm`/`npm`/`yarn`/`bun run
42
+ check`); skip it with `--no-hook`, or add both to a repo you already set up with
43
+ `checkride agent-setup`.
39
44
 
40
45
  ## Commands
41
46
 
42
47
  ```text
43
48
  checkride Run the default checks. Exit 0 pass / 1 fail / 2 error.
44
49
  --only <a,b> --skip <a,b> --bail --json --changed --all --include <a,b>
50
+ --digest --strict (zero checks running = exit 2 — use wherever checkride gates)
45
51
  checkride init Set up a project (new or existing — auto-detected).
46
52
  --shape flat|monorepo|hybrid --name <n> --scope <@s> --license <id> --dry-run
53
+ --baseline (existing mode) grandfather current debt instead of disabling slots
54
+ --no-hook skip writing the Claude Code Stop hook
47
55
  checkride doctor Verify environment + every slot's status (read-only, exit 0/1).
48
56
  checkride fix Run every active adapter's fix command (oxlint --fix, ...).
57
+ checkride baseline Record current diagnostics as a committed baseline.
58
+ checkride agent-setup Add the AGENTS.md stanza + Claude Code Stop hook to a repo.
59
+ --no-hook skip the Stop hook (write only the stanza)
49
60
  ```
50
61
 
51
62
  During iteration, narrow the loop: `checkride --bail`, `checkride --only
@@ -66,6 +77,7 @@ generates config for the blessed default.
66
77
  | Slot | Role | Blessed default | Alternates |
67
78
  | ---------- | -------------------------------------- | ------------------- | ---------------- |
68
79
  | `types` | Type checking | `tsc --build` | — |
80
+ | `format` | Formatting (opt-in) | `prettier` | `biome` |
69
81
  | `lint` | Linting | `oxlint` | `biome`, `eslint`|
70
82
  | `struct` | Structural rules (deep modules) | `ast-grep` | — |
71
83
  | `dead` | Dead code, deps, cycles, boundaries | `fallow` | `knip` |
@@ -75,16 +87,47 @@ generates config for the blessed default.
75
87
  | `spell` | Spelling | `cspell` | — |
76
88
  | `mutation` | Mutation testing (opt-in) | `stryker` | — |
77
89
  | `security` | Dependency audit (opt-in) | `pnpm audit` | — |
90
+ | `publint` | Package publishing lint (opt-in) | `publint` | — |
91
+ | `attw` | Type resolution across module systems (opt-in) | `attw --pack`| — |
78
92
 
79
93
  Zero-config: for each slot, checkride runs the first adapter whose config file
80
94
  exists, and skips slots with no detected tool. The core has **no runtime
81
- dependency** on any checked tool — it spawns `pnpm exec <tool>`; the project
95
+ dependency** on any checked tool — it spawns `<pm> exec <tool>`; the project
82
96
  owns the pinned tool versions.
83
97
 
98
+ **Opt-in slots** (`format`, `mutation`, `security`, `publint`, `attw`) stay out of the
99
+ default run so adopting checkride — or bumping its version — never turns a repo red on a
100
+ check it didn't ask for. Turn one on with `--include <slot>` (or `--all`), or by **naming
101
+ it in `checks`**: an explicit entry like `"format": "prettier"` opts the slot into every
102
+ run. `checkride fix` then runs its write form (e.g. `prettier --write`) alongside the
103
+ other fixers. `format` sits before `lint` so the tree is tidy before the linters look.
104
+
105
+ `publint` and `attw` are the **library-publishing** pair — turn them on for a package you
106
+ ship to npm to make "the published artifact is correct" part of your definition of done.
107
+ `publint` lints `package.json`'s publishing surface (exports, files, types); `attw` runs
108
+ `attw --pack` to check that your types resolve under every module system (`--format json`,
109
+ captured to `.check/attw.json`). Both stay opt-in so apps that never publish don't run
110
+ them.
111
+
112
+ ### Package managers
113
+
114
+ checkride is package-manager-agnostic. It detects the repo's package manager
115
+ from the `packageManager` field or the lockfile (`pnpm-lock.yaml`,
116
+ `package-lock.json`, `yarn.lock`, `bun.lock`), defaulting to **pnpm**, and
117
+ translates each adapter's canonical `pnpm exec <tool>` into that manager's form
118
+ (`npx`, `yarn`, or `bunx`). The default pnpm run is unchanged; `doctor` reports
119
+ the detected manager. One exception: the opt-in `security` slot is `pnpm audit`,
120
+ whose flags and JSON shape are pnpm-specific, so it is **unavailable on a
121
+ non-pnpm manager** until a per-manager audit adapter lands.
122
+
84
123
  ## The `.check/` contract
85
124
 
86
- Every run writes to `.check/`. This is a public API for agents; treat schema
87
- changes as breaking.
125
+ Every run writes to `.check/`. This is a public API for agents — the promised
126
+ surfaces (exit codes, summary shape, flags, exports) are spelled out in
127
+ [docs/contract.md](./docs/contract.md) and locked by a `test/contract/` suite.
128
+ The summary shape is published as a JSON Schema at
129
+ [`schema/checkride.summary.schema.json`](./schema/checkride.summary.schema.json);
130
+ fields are additive-only under a given `schema_version`.
88
131
 
89
132
  - `summary.json` — the aggregate report:
90
133
 
@@ -93,6 +136,7 @@ changes as breaking.
93
136
  "schema_version": 1,
94
137
  "timestamp": "…",
95
138
  "ok": true,
139
+ "checks_run": 8, // checks that actually executed; 0 + ok = vacuous green
96
140
  "total_duration_ms": 4200,
97
141
  "checks": [
98
142
  { "name": "lint", "adapter": "oxlint", "description": "…",
@@ -101,12 +145,32 @@ changes as breaking.
101
145
  }
102
146
  ```
103
147
 
148
+ `ok: true` with `checks_run: 0` means **nothing was verified** — every slot
149
+ sat out (no tool detected, disabled, or skipped). The run warns loudly on
150
+ stderr when that happens, and `--strict` turns it into exit 2, so a gate can
151
+ never mistake "nothing ran" for "everything passed". Anything that gates on
152
+ checkride (CI, commit hooks) should pass `--strict`.
153
+
104
154
  - `<slot>.json` — the raw tool JSON when stdout parses as JSON; otherwise
105
155
  `<slot>.stdout.txt` / `<slot>.stderr.txt`. Tools that write their own files
106
156
  (vitest `--outputFile`, stryker) keep doing so.
107
157
 
158
+ When a [baseline](#baseline) masks a slot's findings, that check gains an additive
159
+ `"baselined": <n>` field counting the grandfathered diagnostics; it is absent on
160
+ runs with no baseline, so `schema_version` is unchanged.
161
+
162
+ - `digest.md` — written only under `--digest`: a **token-bounded** Markdown
163
+ excerpt of the *failing* slots, so an agent working through a big red repo
164
+ reads a capped index instead of every raw file. Each section lists the first few
165
+ findings (reusing the baseline fingerprint extractors, or a tail of raw text
166
+ for slots without one) and links the authoritative `.check/<slot>.json`, which
167
+ is never modified. It **truncates, never normalizes**; a green run leaves no
168
+ digest (any stale one is removed), so its presence always means "this run
169
+ failed". It is a file, never stdout — the machine-output split holds.
170
+
108
171
  To debug a failure: read `summary.json` to find the failing slot, then read that
109
- slot's raw output for structured diagnostics.
172
+ slot's raw output for structured diagnostics. On a large repo, `--digest` writes
173
+ `digest.md` as a capped starting point.
110
174
 
111
175
  ## Configuration
112
176
 
@@ -114,14 +178,17 @@ slot's raw output for structured diagnostics.
114
178
 
115
179
  ```jsonc
116
180
  {
117
- "timeout": 600, // global per-check timeout in seconds (off by default)
181
+ "$schema": "https://raw.githubusercontent.com/robmclarty/checkride/v0.2.1/schema/checkride.config.schema.json",
182
+ "extends": "@acme/checkride-preset", // inherit a shared preset, then override below
183
+ "timeout": 1200, // global per-check timeout in seconds (default: 600)
118
184
  "checks": {
185
+ "format": "prettier", // enable the opt-in format slot (blessed: prettier)
119
186
  "lint": "biome", // pick an alternate adapter
120
187
  "spell": false, // disable a slot
121
188
  "test": { "use": "vitest", "timeout": 0, "changedArgs": ["--changed", "origin/master"] },
122
- "format": { // a custom check that runs FIRST, ahead of the built-ins
189
+ "tidy": { // a bespoke custom check that runs FIRST, ahead of the built-ins
123
190
  "command": "pnpm",
124
- "args": ["exec", "biome", "format", "--write"],
191
+ "args": ["exec", "some-formatter", "--write"],
125
192
  "order": "first"
126
193
  },
127
194
  "licenses": { // a custom check (runs last by default)
@@ -132,19 +199,101 @@ slot's raw output for structured diagnostics.
132
199
  }
133
200
  ```
134
201
 
202
+ The `"$schema"` pointer is optional but recommended: it turns on validation and
203
+ autocompletion for `checkride.config.json` in editors that understand JSON
204
+ Schema (VS Code and friends). `checkride init` writes a version-pinned pointer
205
+ into the config it generates; the schema itself ships in the package at
206
+ [`schema/checkride.config.schema.json`](./schema/checkride.config.schema.json).
207
+
208
+ Use `"extends"` to inherit a shared preset — a file path (`"./base.json"`) or an
209
+ installed package (`"@acme/checkride-preset"`), or an array of them to layer
210
+ several. Bases merge left to right and your local config wins over all of them:
211
+ objects deep-merge (so overriding one field of a check keeps the rest), while
212
+ arrays and scalars replace outright — arrays are **not** concatenated. Pair it
213
+ with `detect` above to publish one org-wide preset that stays safe across repos
214
+ that don't all use the same tools. An `extends` that can't be found, or a config
215
+ that extends itself in a loop, fails fast with
216
+ `invalid checkride.config.json: <reason>`.
217
+
135
218
  A custom check (one keyed by a name that isn't a built-in slot) runs *after* the
136
219
  built-in catalogue by default. Set `"order": "first"` to run it ahead of every
137
- built-in check instead — handy for a formatter like `biome format --write` that
138
- should normalize the tree before the linters and tests look at it. `"order":
139
- "last"` is the explicit form of the default. Within each group, custom checks
140
- run in the order they appear in the config.
141
-
142
- A per-check timeout guards against a hung tool. It is **off by default** — a cap
143
- short enough to catch a hang on a small repo is short enough to kill a legitimate
144
- slow run on a large one, and CI job timeouts already bound true hangs. Set a
145
- global `timeout` (seconds) to opt in, override it per check (`"timeout": <n>`),
146
- and use `"timeout": 0` to exempt a slot. Leave `dead`, `test`, and `mutation`
147
- generous or uncapped — they legitimately run long.
220
+ built-in check instead — handy for a **bespoke** formatter that should normalize
221
+ the tree before the linters and tests look at it. `"order": "last"` is the explicit
222
+ form of the default. Within each group, custom checks run in the order they appear
223
+ in the config.
224
+
225
+ For formatting, the blessed `format` slot (prettier, or biome) is the paved road —
226
+ enable it with `"format": "prettier"` and `checkride fix` writes formatting for you.
227
+ The `order: "first"` custom-check hatch coexists with it, for a one-off formatter the
228
+ slot doesn't cover; the slot didn't retire it.
229
+
230
+ Add `"detect": ["<file>", …]` to a custom check to gate it on marker files: it
231
+ runs only when at least one listed file exists in the repo, and is skipped —
232
+ skipped, not failed — otherwise. This keeps a shared config safe across repos
233
+ that don't all use the same tools: a check for a tool a given repo lacks quietly
234
+ stands down instead of lighting up red. `detect` applies only to custom checks
235
+ that run alongside the catalogue; a custom check that fills a built-in slot
236
+ always runs.
237
+
238
+ A per-check timeout guards against a hung tool, and it is **on by default**: a
239
+ definition-of-done gate that can hang forever fails its one job on the worst
240
+ day. The default cap is a generous **600 seconds per check**; a check that hits
241
+ it gets SIGTERM (then SIGKILL after a short grace) and is recorded as failed
242
+ with a `timed out after 600s` note — red, never vacuous. Tune it with a global
243
+ `timeout` (seconds), override it per check (`"timeout": <n>`), or set
244
+ `"timeout": 0` (globally or per check) to disable the cap. Give `dead`, `test`,
245
+ and `mutation` a higher cap — or `0` — on a large repo where they legitimately
246
+ run long.
247
+
248
+ ## Baseline
249
+
250
+ Adopting checkride on an existing repo shouldn't be a cleanup project. A
251
+ **baseline** grandfathers the diagnostics a repo has *today* so day-one runs pass,
252
+ while any *new* diagnostic still fails — "don't make it worse" as the definition of
253
+ done for legacy code.
254
+
255
+ ```bash
256
+ checkride baseline # record current diagnostics into checkride.baseline.json
257
+ ```
258
+
259
+ `checkride.baseline.json` lives at the repo root beside `checkride.config.json` and
260
+ **is committed** — it must be in version control to work. It records a per-slot set
261
+ of stable *fingerprints* (a `file:rule:message` key that survives line moves), not
262
+ raw output:
263
+
264
+ ```jsonc
265
+ {
266
+ "schema_version": 1,
267
+ "slots": {
268
+ "lint": ["src/legacy.ts:no-explicit-any:Unexpected any"],
269
+ "spell": ["docs/old.md::teh"]
270
+ }
271
+ }
272
+ ```
273
+
274
+ Once it exists, every normal run is **baseline-aware**:
275
+
276
+ - Each slot's current findings have the grandfathered ones subtracted. A slot is
277
+ **green when only baselined findings remain**, and **fails listing only the new
278
+ ones** — the raw `.check/<slot>.json` still holds everything, and the failing
279
+ check gains a `"baselined": <n>` count.
280
+ - The baseline is a **ratchet**: fixing a grandfathered finding prunes it from the
281
+ file (it only ever shrinks), so debt can't silently creep back. A partial run
282
+ (`--only`, `--skip`, `--changed`, or a `--bail` that stops early) never prunes —
283
+ it can't tell an unobserved finding from a fixed one, so it leaves the baseline
284
+ untouched.
285
+ - Never add to the baseline to make a check pass; fix the finding, or re-run
286
+ `checkride baseline` deliberately to re-grandfather.
287
+
288
+ Only slots whose tool has a fingerprint extractor participate (currently `lint` via
289
+ oxlint, `struct` via ast-grep, `spell` via cspell); other slots (`types`, `dead`,
290
+ `test`, …) never appear in the baseline. A crash or empty output is never masked —
291
+ a slot only goes green when there are findings and all of them are grandfathered.
292
+
293
+ To adopt on an existing repo, `checkride init --baseline` grandfathers today's
294
+ failing (fingerprintable) slots into the baseline and keeps them enabled, instead of
295
+ writing them off as `false`; a failing slot with no extractor still falls back to a
296
+ disable.
148
297
 
149
298
  ## Project shapes
150
299
 
@@ -171,7 +320,23 @@ Module boundaries, enforced by `ast-grep` and `fallow`:
171
320
  - Named exports only; no classes; `.js` extensions on relative imports
172
321
  (NodeNext); tests colocated with the code they cover.
173
322
 
174
- See [AGENTS.md](./AGENTS.md) for the contract agents follow, and
323
+ ## Tested envelope
324
+
325
+ Every push runs the full suite — unit, contract, and end-to-end (generated
326
+ projects, installed and checked for real) — on **macOS and Linux**, at **Node
327
+ 22.18.0 (the exact supported floor) and Node 24**, and the e2e suite exercises
328
+ the full package-manager quartet: **pnpm, npm, yarn, and bun**. Windows is not
329
+ tested and not claimed; it waits for a real consumer who needs it.
330
+
331
+ The promised surfaces (exit codes, `summary.json` shape, flags, exports) are
332
+ locked by a dedicated [contract suite](./test/contract/) — see
333
+ [docs/contract.md](./docs/contract.md). Beyond line coverage (enforced at 70%),
334
+ the test suite is itself tested: Stryker mutation testing runs with a hard
335
+ floor of 55; the current mutation score is **67%** (`pnpm mutation` to
336
+ reproduce).
337
+
338
+ See [AGENTS.md](./AGENTS.md) for the contract agents follow,
339
+ [CONTRIBUTING.md](./CONTRIBUTING.md) for the release ritual, and
175
340
  [CHANGELOG.md](./CHANGELOG.md) for release notes.
176
341
 
177
342
  ## License
@@ -6,8 +6,9 @@
6
6
  * data only: no logic lives here. Resolution (config vs detection) lives in
7
7
  * `../config`, and execution lives in `../orchestrator`.
8
8
  *
9
- * Phase 1 ships the blessed defaults plus the two opt-in slots. Alternates
10
- * (biome, knip, eslint, jest) land in Phase 2.
9
+ * Phase 1 ships the blessed defaults plus the opt-in slots (format, mutation,
10
+ * security, and the library-publishing pair publint + attw). Alternates (biome,
11
+ * knip, eslint, jest) land in Phase 2.
11
12
  */
12
13
  /** The aggregate-report schema version written to `.check/summary.json`. */
13
14
  export declare const SCHEMA_VERSION = 1;
@@ -15,7 +16,11 @@ export declare const SCHEMA_VERSION = 1;
15
16
  export type Slot = {
16
17
  /** Stable slot name, e.g. `'lint'`. Used by `--only`/`--skip` and the report. */
17
18
  name: string;
18
- /** Opt-in slots are excluded from the default run (need `--all`/`--include`). */
19
+ /**
20
+ * Opt-in slots are excluded from the default run. Enable one with
21
+ * `--all`/`--include <slot>`, or by naming it in `checks` (an explicit config
22
+ * entry opts you in — see `resolveChecks`/`selectChecks`).
23
+ */
19
24
  optIn?: boolean;
20
25
  };
21
26
  /** A concrete tool that can fill a slot. */
@@ -38,7 +43,7 @@ export type Adapter = {
38
43
  changedArgs?: string[];
39
44
  /** Used by `checkride fix`. */
40
45
  fixArgs?: string[];
41
- /** Per-check timeout in seconds; `0` disables the cap. Falls back to the config-level `timeout`. */
46
+ /** Per-check timeout in seconds; `0` disables the cap. Falls back to the config-level `timeout`, then the built-in 600s default. */
42
47
  timeout?: number;
43
48
  /** In-process check id (e.g. `'links'`); when set, the orchestrator runs it directly. */
44
49
  builtin?: string;
@@ -1 +1 @@
1
- {"version":3,"file":"adapters.d.ts","sourceRoot":"","sources":["../src/adapters.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,4EAA4E;AAC5E,eAAO,MAAM,cAAc,IAAI,CAAC;AAEhC,8BAA8B;AAC9B,MAAM,MAAM,IAAI,GAAG;IACjB,iFAAiF;IACjF,IAAI,EAAE,MAAM,CAAC;IACb,iFAAiF;IACjF,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB,CAAC;AAEF,4CAA4C;AAC5C,MAAM,MAAM,OAAO,GAAG;IACpB,0EAA0E;IAC1E,IAAI,EAAE,MAAM,CAAC;IAC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ACnF,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,0EAA0E;IAC1E,OAAO,EAAE,MAAM,CAAC;IAChB,+DAA+D;IAC/D,IAAI,EAAE,MAAM,EAAE,CAAC;IACf,qFAAqF;IACrF,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,4CAA4C;IAC5C,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB,+BAA+B;IAC/B,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,oIAAoI;IACpI,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,yFAAyF;IACzF,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,uDAAuD;IACvD,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACjC,CAAC;AAEF,6DAA6D;AAC7D,eAAO,MAAM,KAAK,EAAE,SAAS,IAAI,EAchC,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,QAAQ,EAAE,SAAS,OAAO,EAkPtC,CAAC"}
@@ -6,14 +6,16 @@
6
6
  * data only: no logic lives here. Resolution (config vs detection) lives in
7
7
  * `../config`, and execution lives in `../orchestrator`.
8
8
  *
9
- * Phase 1 ships the blessed defaults plus the two opt-in slots. Alternates
10
- * (biome, knip, eslint, jest) land in Phase 2.
9
+ * Phase 1 ships the blessed defaults plus the opt-in slots (format, mutation,
10
+ * security, and the library-publishing pair publint + attw). Alternates (biome,
11
+ * knip, eslint, jest) land in Phase 2.
11
12
  */
12
13
  /** The aggregate-report schema version written to `.check/summary.json`. */
13
14
  export const SCHEMA_VERSION = 1;
14
15
  /** Pipeline order. Cheapest first so `--bail` fails fast. */
15
16
  export const SLOTS = [
16
17
  { name: 'types' },
18
+ { name: 'format', optIn: true },
17
19
  { name: 'lint' },
18
20
  { name: 'struct' },
19
21
  { name: 'dead' },
@@ -23,6 +25,8 @@ export const SLOTS = [
23
25
  { name: 'spell' },
24
26
  { name: 'mutation', optIn: true },
25
27
  { name: 'security', optIn: true },
28
+ { name: 'publint', optIn: true },
29
+ { name: 'attw', optIn: true },
26
30
  ];
27
31
  /**
28
32
  * Adapter registry. The FIRST adapter for a slot is its blessed default: it
@@ -40,6 +44,42 @@ export const ADAPTERS = [
40
44
  outputFile: null,
41
45
  devDeps: { typescript: '6.0.3', '@types/node': '22.20.0' },
42
46
  },
47
+ {
48
+ name: 'prettier',
49
+ slot: 'format',
50
+ description: 'Prettier formatting check',
51
+ detect: [
52
+ '.prettierrc',
53
+ '.prettierrc.json',
54
+ '.prettierrc.yml',
55
+ '.prettierrc.yaml',
56
+ '.prettierrc.json5',
57
+ '.prettierrc.js',
58
+ '.prettierrc.cjs',
59
+ '.prettierrc.mjs',
60
+ '.prettierrc.toml',
61
+ 'prettier.config.js',
62
+ 'prettier.config.cjs',
63
+ 'prettier.config.mjs',
64
+ 'prettier.config.ts',
65
+ ],
66
+ command: 'pnpm',
67
+ args: ['exec', 'prettier', '--check', '.'],
68
+ outputFile: null,
69
+ fixArgs: ['exec', 'prettier', '--write', '.'],
70
+ devDeps: { prettier: '3.6.2' },
71
+ },
72
+ {
73
+ name: 'biome-format',
74
+ slot: 'format',
75
+ description: 'Biome formatting check',
76
+ detect: ['biome.json', 'biome.jsonc'],
77
+ command: 'pnpm',
78
+ args: ['exec', 'biome', 'format', '.'],
79
+ outputFile: null,
80
+ fixArgs: ['exec', 'biome', 'format', '--write', '.'],
81
+ devDeps: { '@biomejs/biome': '2.2.4' },
82
+ },
43
83
  {
44
84
  name: 'oxlint',
45
85
  slot: 'lint',
@@ -215,5 +255,25 @@ export const ADAPTERS = [
215
255
  outputFile: 'security.json',
216
256
  devDeps: {},
217
257
  },
258
+ {
259
+ name: 'publint',
260
+ slot: 'publint',
261
+ description: 'publint: package.json publishing correctness',
262
+ detect: [],
263
+ command: 'pnpm',
264
+ args: ['exec', 'publint'],
265
+ outputFile: null,
266
+ devDeps: { publint: '0.3.21' },
267
+ },
268
+ {
269
+ name: 'attw',
270
+ slot: 'attw',
271
+ description: 'Are the types wrong? (type resolution across module systems)',
272
+ detect: [],
273
+ command: 'pnpm',
274
+ args: ['exec', 'attw', '--pack', '.', '--format', 'json'],
275
+ outputFile: 'attw.json',
276
+ devDeps: { '@arethetypeswrong/cli': '0.18.4' },
277
+ },
218
278
  ];
219
279
  //# sourceMappingURL=adapters.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"adapters.js","sourceRoot":"","sources":["../src/adapters.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,4EAA4E;AAC5E,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,CAAC;AAsChC,6DAA6D;AAC7D,MAAM,CAAC,MAAM,KAAK,GAAoB;IACpC,EAAE,IAAI,EAAE,OAAO,EAAE;IACjB,EAAE,IAAI,EAAE,MAAM,EAAE;IAChB,EAAE,IAAI,EAAE,QAAQ,EAAE;IAClB,EAAE,IAAI,EAAE,MAAM,EAAE;IAChB,EAAE,IAAI,EAAE,MAAM,EAAE;IAChB,EAAE,IAAI,EAAE,MAAM,EAAE;IAChB,EAAE,IAAI,EAAE,OAAO,EAAE;IACjB,EAAE,IAAI,EAAE,OAAO,EAAE;IACjB,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,IAAI,EAAE;IACjC,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,IAAI,EAAE;CAClC,CAAC;AAEF;;;;GAIG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAuB;IAC1C;QACE,IAAI,EAAE,KAAK;QACX,IAAI,EAAE,OAAO;QACb,WAAW,EAAE,gEAAgE;QAC7E,MAAM,EAAE,CAAC,eAAe,CAAC;QACzB,OAAO,EAAE,MAAM;QACf,IAAI,EAAE,CAAC,MAAM,EAAE,KAAK,EAAE,SAAS,CAAC;QAChC,UAAU,EAAE,IAAI;QAChB,OAAO,EAAE,EAAE,UAAU,EAAE,OAAO,EAAE,aAAa,EAAE,SAAS,EAAE;KAC3D;IACD;QACE,IAAI,EAAE,QAA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