@company-semantics/contracts 0.23.1 → 0.24.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@company-semantics/contracts",
3
- "version": "0.23.1",
3
+ "version": "0.24.0",
4
4
  "private": false,
5
5
  "repository": {
6
6
  "type": "git",
@@ -55,7 +55,7 @@
55
55
  "guard:version-tag:json": "npx tsx scripts/ci/version-tag-guard.ts --json",
56
56
  "guard:test": "vitest run scripts/ci/__tests__",
57
57
  "release": "npx tsx scripts/release.ts",
58
- "prepublishOnly": "pnpm guard:version-tag",
58
+ "prepublishOnly": "echo 'ERROR: Publishing is CI-only via tag push. Use pnpm release instead.' && exit 1",
59
59
  "test": "vitest run scripts/ci/__tests__"
60
60
  },
61
61
  "packageManager": "pnpm@10.25.0",
@@ -207,6 +207,18 @@ export interface VulnerabilitiesBaseline {
207
207
  }>;
208
208
  }
209
209
 
210
+ /**
211
+ * Contracts consumer guard configuration.
212
+ * Enforces: consumers never advance ahead of npm.
213
+ *
214
+ * Verifies that the @company-semantics/contracts version specified
215
+ * in package.json exists on npm before allowing consumer updates.
216
+ */
217
+ export interface ContractsConsumerBaseline {
218
+ /** Path to package.json relative to repo root */
219
+ packageJsonPath: string;
220
+ }
221
+
210
222
  /**
211
223
  * Structural guard baselines.
212
224
  * Product repos provide DATA only; CI orchestrator owns guard implementations.
@@ -226,6 +238,13 @@ export interface StructuralBaselines {
226
238
  * CI injects checkVulnerabilities based on this config.
227
239
  */
228
240
  vulnerabilities?: VulnerabilitiesBaseline;
241
+
242
+ /**
243
+ * Contracts consumer check configuration.
244
+ * CI injects checkContractsConsumer based on this config.
245
+ * Enforces: consumers never advance ahead of npm.
246
+ */
247
+ contractsConsumer?: ContractsConsumerBaseline;
229
248
  }
230
249
 
231
250
  /**
@@ -47,6 +47,7 @@ export type {
47
47
  StructuralBaselines,
48
48
  ScriptsDepsBaseline,
49
49
  VulnerabilitiesBaseline,
50
+ ContractsConsumerBaseline,
50
51
  EvolutionBaselines,
51
52
  ContractsFreshnessBaseline,
52
53
  CoverageBaseline,