repo-contract 0.3.0 → 0.4.0

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 (137) hide show
  1. package/CHANGELOG.md +60 -0
  2. package/README.md +124 -923
  3. package/bin/package-json-patch.d.mts +9 -0
  4. package/bin/package-json-patch.mjs +221 -0
  5. package/bin/preset-catalog.d.mts +39 -0
  6. package/bin/preset-catalog.mjs +71 -0
  7. package/bin/repo-contract.mjs +222 -0
  8. package/bin/templates.d.mts +5 -0
  9. package/bin/templates.mjs +74 -0
  10. package/dist/.dts/config/define-repo-contract.d.ts +36 -0
  11. package/dist/.dts/config/define-repo-contract.d.ts.map +1 -0
  12. package/dist/.dts/config/tokenize-command.d.ts +33 -0
  13. package/dist/.dts/config/tokenize-command.d.ts.map +1 -0
  14. package/dist/.dts/config/validate-config.d.ts +32 -0
  15. package/dist/.dts/config/validate-config.d.ts.map +1 -0
  16. package/dist/.dts/errors.d.ts +172 -0
  17. package/dist/.dts/errors.d.ts.map +1 -0
  18. package/dist/.dts/evidence/build-evidence.d.ts +26 -0
  19. package/dist/.dts/evidence/build-evidence.d.ts.map +1 -0
  20. package/dist/.dts/execution/abort-signals.d.ts +29 -0
  21. package/dist/.dts/execution/abort-signals.d.ts.map +1 -0
  22. package/dist/.dts/execution/concurrency-pool.d.ts +14 -0
  23. package/dist/.dts/execution/concurrency-pool.d.ts.map +1 -0
  24. package/dist/.dts/execution/dependency-scheduler.d.ts +30 -0
  25. package/dist/.dts/execution/dependency-scheduler.d.ts.map +1 -0
  26. package/dist/.dts/execution/process-tree.d.ts +59 -0
  27. package/dist/.dts/execution/process-tree.d.ts.map +1 -0
  28. package/dist/.dts/execution/run-checks.d.ts +31 -0
  29. package/dist/.dts/execution/run-checks.d.ts.map +1 -0
  30. package/dist/.dts/execution/spawn-check.d.ts +49 -0
  31. package/dist/.dts/execution/spawn-check.d.ts.map +1 -0
  32. package/dist/.dts/helpers/exception-policy.d.ts +199 -0
  33. package/dist/.dts/helpers/exception-policy.d.ts.map +1 -0
  34. package/dist/.dts/helpers/index.d.ts +34 -0
  35. package/dist/.dts/helpers/index.d.ts.map +1 -0
  36. package/dist/.dts/helpers/load-exception-registry.d.ts +41 -0
  37. package/dist/.dts/helpers/load-exception-registry.d.ts.map +1 -0
  38. package/dist/.dts/helpers/reconcile-exceptions.d.ts +91 -0
  39. package/dist/.dts/helpers/reconcile-exceptions.d.ts.map +1 -0
  40. package/dist/.dts/helpers/write-exception-registry.d.ts +45 -0
  41. package/dist/.dts/helpers/write-exception-registry.d.ts.map +1 -0
  42. package/dist/.dts/index.d.ts +14 -0
  43. package/dist/.dts/index.d.ts.map +1 -0
  44. package/dist/.dts/parsing/format-schema-issues.d.ts +11 -0
  45. package/dist/.dts/parsing/format-schema-issues.d.ts.map +1 -0
  46. package/dist/.dts/parsing/parse-json.d.ts +8 -0
  47. package/dist/.dts/parsing/parse-json.d.ts.map +1 -0
  48. package/dist/.dts/parsing/parse-output.d.ts +25 -0
  49. package/dist/.dts/parsing/parse-output.d.ts.map +1 -0
  50. package/dist/.dts/parsing/parse-text.d.ts +8 -0
  51. package/dist/.dts/parsing/parse-text.d.ts.map +1 -0
  52. package/dist/.dts/parsing/parse-yaml.d.ts +21 -0
  53. package/dist/.dts/parsing/parse-yaml.d.ts.map +1 -0
  54. package/dist/.dts/policy/run-policies.d.ts +38 -0
  55. package/dist/.dts/policy/run-policies.d.ts.map +1 -0
  56. package/dist/.dts/presets/arethetypeswrong.d.ts +39 -0
  57. package/dist/.dts/presets/arethetypeswrong.d.ts.map +1 -0
  58. package/dist/.dts/presets/broken-links.d.ts +16 -0
  59. package/dist/.dts/presets/broken-links.d.ts.map +1 -0
  60. package/dist/.dts/presets/commitlint.d.ts +22 -0
  61. package/dist/.dts/presets/commitlint.d.ts.map +1 -0
  62. package/dist/.dts/presets/dead-code.d.ts +23 -0
  63. package/dist/.dts/presets/dead-code.d.ts.map +1 -0
  64. package/dist/.dts/presets/duplication.d.ts +14 -0
  65. package/dist/.dts/presets/duplication.d.ts.map +1 -0
  66. package/dist/.dts/presets/e2e.d.ts +4 -0
  67. package/dist/.dts/presets/e2e.d.ts.map +1 -0
  68. package/dist/.dts/presets/format.d.ts +4 -0
  69. package/dist/.dts/presets/format.d.ts.map +1 -0
  70. package/dist/.dts/presets/index.d.ts +31 -0
  71. package/dist/.dts/presets/index.d.ts.map +1 -0
  72. package/dist/.dts/presets/license.d.ts +4 -0
  73. package/dist/.dts/presets/license.d.ts.map +1 -0
  74. package/dist/.dts/presets/lint.d.ts +20 -0
  75. package/dist/.dts/presets/lint.d.ts.map +1 -0
  76. package/dist/.dts/presets/markdownlint.d.ts +23 -0
  77. package/dist/.dts/presets/markdownlint.d.ts.map +1 -0
  78. package/dist/.dts/presets/publint.d.ts +13 -0
  79. package/dist/.dts/presets/publint.d.ts.map +1 -0
  80. package/dist/.dts/presets/security-deps.d.ts +4 -0
  81. package/dist/.dts/presets/security-deps.d.ts.map +1 -0
  82. package/dist/.dts/presets/security-secrets.d.ts +4 -0
  83. package/dist/.dts/presets/security-secrets.d.ts.map +1 -0
  84. package/dist/.dts/presets/shared/error-warning-pass-policy.d.ts +13 -0
  85. package/dist/.dts/presets/shared/error-warning-pass-policy.d.ts.map +1 -0
  86. package/dist/.dts/presets/shared/exit-code-fail-rationale.d.ts +23 -0
  87. package/dist/.dts/presets/shared/exit-code-fail-rationale.d.ts.map +1 -0
  88. package/dist/.dts/presets/shared/missing-dependency.d.ts +19 -0
  89. package/dist/.dts/presets/shared/missing-dependency.d.ts.map +1 -0
  90. package/dist/.dts/presets/shared/read-json-report.d.ts +33 -0
  91. package/dist/.dts/presets/shared/read-json-report.d.ts.map +1 -0
  92. package/dist/.dts/presets/shared/terminal-status.d.ts +25 -0
  93. package/dist/.dts/presets/shared/terminal-status.d.ts.map +1 -0
  94. package/dist/.dts/presets/shared/vitest-json-policy.d.ts +20 -0
  95. package/dist/.dts/presets/shared/vitest-json-policy.d.ts.map +1 -0
  96. package/dist/.dts/presets/stylelint.d.ts +17 -0
  97. package/dist/.dts/presets/stylelint.d.ts.map +1 -0
  98. package/dist/.dts/presets/test.d.ts +4 -0
  99. package/dist/.dts/presets/test.d.ts.map +1 -0
  100. package/dist/.dts/presets/typecheck.d.ts +4 -0
  101. package/dist/.dts/presets/typecheck.d.ts.map +1 -0
  102. package/dist/.dts/run-repo-contract.d.ts +38 -0
  103. package/dist/.dts/run-repo-contract.d.ts.map +1 -0
  104. package/dist/.dts/standard-schema/types.d.ts +76 -0
  105. package/dist/.dts/standard-schema/types.d.ts.map +1 -0
  106. package/dist/.dts/types.d.ts +424 -0
  107. package/dist/.dts/types.d.ts.map +1 -0
  108. package/dist/helpers.cjs +306 -0
  109. package/dist/helpers.cjs.map +1 -0
  110. package/dist/helpers.d.cts +1 -0
  111. package/dist/helpers.d.ts +1 -0
  112. package/dist/helpers.js +296 -0
  113. package/dist/helpers.js.map +1 -0
  114. package/dist/index.cjs +92 -3
  115. package/dist/index.cjs.map +1 -1
  116. package/dist/index.d.cts +1 -0
  117. package/dist/index.d.ts +1 -0
  118. package/dist/index.js +92 -4
  119. package/dist/index.js.map +1 -1
  120. package/dist/presets.d.cts +1 -0
  121. package/dist/presets.d.ts +1 -0
  122. package/helpers/package.json +5 -0
  123. package/package.json +25 -3
  124. package/schemas/evidence.schema.json +2 -2
  125. package/src/config/validate-config.ts +55 -1
  126. package/src/errors.ts +26 -0
  127. package/src/evidence/build-evidence.ts +6 -1
  128. package/src/helpers/exception-policy.ts +421 -0
  129. package/src/helpers/index.ts +57 -0
  130. package/src/helpers/load-exception-registry.ts +136 -0
  131. package/src/helpers/reconcile-exceptions.ts +171 -0
  132. package/src/helpers/write-exception-registry.ts +136 -0
  133. package/src/index.ts +3 -0
  134. package/src/parsing/format-schema-issues.ts +56 -0
  135. package/src/parsing/parse-output.ts +50 -3
  136. package/src/standard-schema/types.ts +93 -0
  137. package/src/types.ts +48 -12
package/CHANGELOG.md CHANGED
@@ -1,5 +1,65 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.4.0](https://github.com/MaverickCER/repo-contract/compare/repo-contract-v0.3.2...repo-contract-v0.4.0) (2026-09-09)
4
+
5
+
6
+ ### ⚠ BREAKING CHANGES
7
+
8
+ * adds the new Experimental repo-contract/helpers subpath (exception-policy primitive). No existing export's shape changes; classified as minor per VERSIONING.md's "a new preset -> minor" convention for the Experimental tier, not a literal incompatibility.
9
+
10
+ ### Features
11
+
12
+ * add a narrow `repo-contract init` scaffolding command ([#63](https://github.com/MaverickCER/repo-contract/issues/63)) ([a1d4e4a](https://github.com/MaverickCER/repo-contract/commit/a1d4e4a242cb0253e0a62e486e86a475a5c8ddbd))
13
+ * add a verified-exception waiver path to security-network ([94dbf43](https://github.com/MaverickCER/repo-contract/commit/94dbf4321b9288b10c65e7efc3e2596a40f4c628))
14
+ * add security-socket and coderabbitai checks ([cb7d3ca](https://github.com/MaverickCER/repo-contract/commit/cb7d3cad8d8015e85c82731075abe48e12371b15))
15
+ * add security-socket and coderabbitai checks ([31374ee](https://github.com/MaverickCER/repo-contract/commit/31374eebe5c35ff54e3efd37d5ed756cc8b8cdc4))
16
+ * add the checks/shared exception-matching and identity layer ([0d711f5](https://github.com/MaverickCER/repo-contract/commit/0d711f5f17d382af507cfafab4a441d620a8b220))
17
+ * add the generic exception-policy core primitive ([8d8f670](https://github.com/MaverickCER/repo-contract/commit/8d8f6704c20bc2c5a4b07e68dcb8e328ee48b9c7))
18
+ * content-bound verification for suppression-governance ([fb6a838](https://github.com/MaverickCER/repo-contract/commit/fb6a838da76247cc42ab316ad9d420ff174a4124))
19
+ * content-bound verification for suppression-governance (disable-comments.json) ([8da651a](https://github.com/MaverickCER/repo-contract/commit/8da651a0f76ab0464ed3b22ac5113b837ea3ecc1))
20
+ * **helpers:** add the exception-registry lifecycle primitives ([de8e855](https://github.com/MaverickCER/repo-contract/commit/de8e8558a26ca238aafc69d736e576aafddd8fa0))
21
+ * publish the repo-contract/helpers subpath ([35f168c](https://github.com/MaverickCER/repo-contract/commit/35f168ca9fbde4f46d1a29624f112e0d4d3b296d))
22
+ * retrofit security-network onto the exception-policy primitive ([62b8d0a](https://github.com/MaverickCER/repo-contract/commit/62b8d0afae9f3958b60666531d58a25a6f5b796e))
23
+
24
+
25
+ ### Bug Fixes
26
+
27
+ * address CodeRabbit findings on the security-network retrofit ([e53313e](https://github.com/MaverickCER/repo-contract/commit/e53313ecf2973649cc2dca045a220f27f0e205db))
28
+ * address CodeRabbit findings on the two new checks ([255e495](https://github.com/MaverickCER/repo-contract/commit/255e49584a2b6622cee174f560221e731932d840))
29
+ * address CodeRabbit findings on the verification retrofit ([3d91878](https://github.com/MaverickCER/repo-contract/commit/3d91878407dd006f82239d034cb319d3856a0c46))
30
+ * address round-2 CodeRabbit findings on the helpers primitive ([fabb9df](https://github.com/MaverickCER/repo-contract/commit/fabb9df2261051cc35fbe15faf3e6df9317afdf5))
31
+ * backfill verification baseline onto records merged in from main ([286e877](https://github.com/MaverickCER/repo-contract/commit/286e8775ad66d7d727f68c0ba269ad2cfa036d56))
32
+ * harden exception-policy config validation and smoke/license accuracy ([e23c069](https://github.com/MaverickCER/repo-contract/commit/e23c069f422ac8967cf8c3a65605bdfb85c07abc))
33
+ * reject impossible calendar dates in verifiedAt, sync ADR 0013 ([6df0911](https://github.com/MaverickCER/repo-contract/commit/6df0911c8bbbfe99bd97095e811b9d762aeb6438))
34
+ * reject trailing newline in verifiedAt; PATH-aware socket probe in the integration test ([ef01ba6](https://github.com/MaverickCER/repo-contract/commit/ef01ba65950041838a3e43f8d8f440add6c4a97c))
35
+ * remove duplicate StandardSchemaV1 re-export in src/helpers/index.ts ([a0d8ee7](https://github.com/MaverickCER/repo-contract/commit/a0d8ee7a490d05fc99d9cbb7150706f7c1494694))
36
+ * skip the real-source drift test inside a Stryker mutation sandbox ([e9e64f6](https://github.com/MaverickCER/repo-contract/commit/e9e64f6dbe57a9e0612209bb568b584961d130cc))
37
+ * validate exception registries on every run and tighten verification ([8d6993f](https://github.com/MaverickCER/repo-contract/commit/8d6993fb94299a50c7b2589d400e592e43767df5))
38
+ * validate the coderabbit terminal event findings count ([a7acd09](https://github.com/MaverickCER/repo-contract/commit/a7acd0950b54f3bd2dbde3956a697d97d80daf9c))
39
+
40
+ ## [0.3.2](https://github.com/MaverickCER/repo-contract/compare/repo-contract-v0.3.1...repo-contract-v0.3.2) (2026-09-04)
41
+
42
+
43
+ ### Features
44
+
45
+ * validate and transform check output with a Standard Schema ([d53cb17](https://github.com/MaverickCER/repo-contract/commit/d53cb17a9e3a3f939cd403226ab5256be0de79ac))
46
+ * validate and transform check output with a Standard Schema ([fbb7925](https://github.com/MaverickCER/repo-contract/commit/fbb79259f4a6cede1da64a0abd7e1f1541e1d505))
47
+
48
+
49
+ ### Bug Fixes
50
+
51
+ * address CodeRabbit findings and close mutation-testing gaps in Standard Schema support ([53baf87](https://github.com/MaverickCER/repo-contract/commit/53baf877d367fd17dbe1ec2f312ab9ed790e6ae6))
52
+ * **api-contract:** don't classify a required property on a brand-new container as breaking ([27ad5d5](https://github.com/MaverickCER/repo-contract/commit/27ad5d5c57811d90393b00f48ae8a8bbd413407b))
53
+ * **test:** harden isRuntimeAvailable against spawnSync throwing under load ([60c76b6](https://github.com/MaverickCER/repo-contract/commit/60c76b642dfd6187888f02d31639e68468e77b17))
54
+
55
+ ## [0.3.1](https://github.com/MaverickCER/repo-contract/compare/repo-contract-v0.3.0...repo-contract-v0.3.1) (2026-09-03)
56
+
57
+
58
+ ### Bug Fixes
59
+
60
+ * correct the release runbook that shipped types-less tarballs ([f56ea34](https://github.com/MaverickCER/repo-contract/commit/f56ea342606cfc92a09943ea5eb787936e7b7ba9))
61
+ * published tarball missing types; simplify CI matrix ([7ec8fd9](https://github.com/MaverickCER/repo-contract/commit/7ec8fd946bd584098255c5d2ab3f07b98b55ba1f))
62
+
3
63
  ## [0.3.0](https://github.com/MaverickCER/repo-contract/compare/repo-contract-v0.2.1...repo-contract-v0.3.0) (2026-09-03)
4
64
 
5
65