@goodbones/core 0.1.0-beta.1 → 0.1.0-beta.10

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 (164) hide show
  1. package/build/dts/core/campaigns.d.ts +141 -0
  2. package/build/dts/core/campaigns.d.ts.map +1 -0
  3. package/build/dts/core/coverage.d.ts +20 -0
  4. package/build/dts/core/coverage.d.ts.map +1 -1
  5. package/build/dts/core/graph.d.ts +2 -0
  6. package/build/dts/core/graph.d.ts.map +1 -1
  7. package/build/dts/core/imports.d.ts +3 -1
  8. package/build/dts/core/imports.d.ts.map +1 -1
  9. package/build/dts/core/ledger.d.ts +61 -0
  10. package/build/dts/core/ledger.d.ts.map +1 -0
  11. package/build/dts/core/slack.d.ts +22 -0
  12. package/build/dts/core/slack.d.ts.map +1 -0
  13. package/build/dts/core/structure.d.ts +1 -0
  14. package/build/dts/core/structure.d.ts.map +1 -1
  15. package/build/dts/domain/architecture-config.d.ts +324 -1
  16. package/build/dts/domain/architecture-config.d.ts.map +1 -1
  17. package/build/dts/domain/architecture-error.d.ts +8 -0
  18. package/build/dts/domain/architecture-error.d.ts.map +1 -1
  19. package/build/dts/domain/facts.d.ts +1 -0
  20. package/build/dts/domain/facts.d.ts.map +1 -1
  21. package/build/dts/domain/manifest-location.d.ts +9 -0
  22. package/build/dts/domain/manifest-location.d.ts.map +1 -0
  23. package/build/dts/domain/report.d.ts +16 -0
  24. package/build/dts/domain/report.d.ts.map +1 -0
  25. package/build/dts/domain/snapshot.d.ts +224 -0
  26. package/build/dts/domain/snapshot.d.ts.map +1 -0
  27. package/build/dts/domain/violation.d.ts +1 -1
  28. package/build/dts/domain/violation.d.ts.map +1 -1
  29. package/build/dts/index.d.ts +24 -9
  30. package/build/dts/index.d.ts.map +1 -1
  31. package/build/dts/infrastructure/campaign-functions.d.ts +7 -0
  32. package/build/dts/infrastructure/campaign-functions.d.ts.map +1 -0
  33. package/build/dts/infrastructure/manifest-file.d.ts +11 -2
  34. package/build/dts/infrastructure/manifest-file.d.ts.map +1 -1
  35. package/build/dts/infrastructure/manifest-include.d.ts +16 -0
  36. package/build/dts/infrastructure/manifest-include.d.ts.map +1 -0
  37. package/build/dts/infrastructure/report-source-fake.d.ts +4 -0
  38. package/build/dts/infrastructure/report-source-fake.d.ts.map +1 -0
  39. package/build/dts/infrastructure/report-source-live.d.ts +3 -0
  40. package/build/dts/infrastructure/report-source-live.d.ts.map +1 -0
  41. package/build/dts/infrastructure/syntax-matcher-fake.d.ts +10 -0
  42. package/build/dts/infrastructure/syntax-matcher-fake.d.ts.map +1 -0
  43. package/build/dts/infrastructure/walk.d.ts +6 -0
  44. package/build/dts/infrastructure/walk.d.ts.map +1 -1
  45. package/build/dts/load/policy.d.ts +16 -0
  46. package/build/dts/load/policy.d.ts.map +1 -1
  47. package/build/dts/manifest/compile.d.ts +7 -2
  48. package/build/dts/manifest/compile.d.ts.map +1 -1
  49. package/build/dts/manifest/expand.d.ts +27 -0
  50. package/build/dts/manifest/expand.d.ts.map +1 -0
  51. package/build/dts/manifest/infer.d.ts +55 -0
  52. package/build/dts/manifest/infer.d.ts.map +1 -0
  53. package/build/dts/manifest/json-schema.d.ts +10 -0
  54. package/build/dts/manifest/json-schema.d.ts.map +1 -0
  55. package/build/dts/manifest/manifest.d.ts +381 -1
  56. package/build/dts/manifest/manifest.d.ts.map +1 -1
  57. package/build/dts/ports/campaign-predicate.d.ts +24 -0
  58. package/build/dts/ports/campaign-predicate.d.ts.map +1 -0
  59. package/build/dts/ports/language.d.ts +4 -0
  60. package/build/dts/ports/language.d.ts.map +1 -1
  61. package/build/dts/ports/report-source.d.ts +14 -0
  62. package/build/dts/ports/report-source.d.ts.map +1 -0
  63. package/build/dts/ports/syntax-matcher.d.ts +21 -0
  64. package/build/dts/ports/syntax-matcher.d.ts.map +1 -0
  65. package/build/dts/testing.d.ts +2 -0
  66. package/build/dts/testing.d.ts.map +1 -1
  67. package/build/esm/core/campaigns.js +778 -0
  68. package/build/esm/core/campaigns.js.map +1 -0
  69. package/build/esm/core/coverage.js +107 -32
  70. package/build/esm/core/coverage.js.map +1 -1
  71. package/build/esm/core/graph.js +45 -0
  72. package/build/esm/core/graph.js.map +1 -1
  73. package/build/esm/core/imports.js +14 -9
  74. package/build/esm/core/imports.js.map +1 -1
  75. package/build/esm/core/ledger.js +171 -0
  76. package/build/esm/core/ledger.js.map +1 -0
  77. package/build/esm/core/slack.js +76 -0
  78. package/build/esm/core/slack.js.map +1 -0
  79. package/build/esm/core/structure.js +5 -2
  80. package/build/esm/core/structure.js.map +1 -1
  81. package/build/esm/domain/architecture-config.js +158 -1
  82. package/build/esm/domain/architecture-config.js.map +1 -1
  83. package/build/esm/domain/architecture-error.js +27 -0
  84. package/build/esm/domain/architecture-error.js.map +1 -1
  85. package/build/esm/domain/manifest-location.js +21 -0
  86. package/build/esm/domain/manifest-location.js.map +1 -0
  87. package/build/esm/domain/report.js +168 -0
  88. package/build/esm/domain/report.js.map +1 -0
  89. package/build/esm/domain/snapshot.js +141 -0
  90. package/build/esm/domain/snapshot.js.map +1 -0
  91. package/build/esm/domain/violation.js.map +1 -1
  92. package/build/esm/index.js +21 -8
  93. package/build/esm/index.js.map +1 -1
  94. package/build/esm/infrastructure/campaign-functions.js +67 -0
  95. package/build/esm/infrastructure/campaign-functions.js.map +1 -0
  96. package/build/esm/infrastructure/manifest-file.js +158 -7
  97. package/build/esm/infrastructure/manifest-file.js.map +1 -1
  98. package/build/esm/infrastructure/manifest-include.js +187 -0
  99. package/build/esm/infrastructure/manifest-include.js.map +1 -0
  100. package/build/esm/infrastructure/report-source-fake.js +6 -0
  101. package/build/esm/infrastructure/report-source-fake.js.map +1 -0
  102. package/build/esm/infrastructure/report-source-live.js +165 -0
  103. package/build/esm/infrastructure/report-source-live.js.map +1 -0
  104. package/build/esm/infrastructure/syntax-matcher-fake.js +33 -0
  105. package/build/esm/infrastructure/syntax-matcher-fake.js.map +1 -0
  106. package/build/esm/infrastructure/walk.js +57 -1
  107. package/build/esm/infrastructure/walk.js.map +1 -1
  108. package/build/esm/load/policy.js +123 -3
  109. package/build/esm/load/policy.js.map +1 -1
  110. package/build/esm/manifest/compile.js +228 -26
  111. package/build/esm/manifest/compile.js.map +1 -1
  112. package/build/esm/manifest/expand.js +116 -0
  113. package/build/esm/manifest/expand.js.map +1 -0
  114. package/build/esm/manifest/infer.js +455 -0
  115. package/build/esm/manifest/infer.js.map +1 -0
  116. package/build/esm/manifest/json-schema.js +135 -0
  117. package/build/esm/manifest/json-schema.js.map +1 -0
  118. package/build/esm/manifest/manifest.js +243 -5
  119. package/build/esm/manifest/manifest.js.map +1 -1
  120. package/build/esm/ports/campaign-predicate.js +2 -0
  121. package/build/esm/ports/campaign-predicate.js.map +1 -0
  122. package/build/esm/ports/report-source.js +7 -0
  123. package/build/esm/ports/report-source.js.map +1 -0
  124. package/build/esm/ports/syntax-matcher.js +12 -0
  125. package/build/esm/ports/syntax-matcher.js.map +1 -0
  126. package/build/esm/testing.js +2 -0
  127. package/build/esm/testing.js.map +1 -1
  128. package/package.json +9 -3
  129. package/schema/architecture-node.schema.json +2405 -0
  130. package/schema/architecture.schema.json +2825 -0
  131. package/schema/conformance.schema.json +775 -0
  132. package/src/core/campaigns.ts +1056 -0
  133. package/src/core/coverage.ts +164 -34
  134. package/src/core/graph.ts +48 -0
  135. package/src/core/imports.ts +29 -13
  136. package/src/core/ledger.ts +242 -0
  137. package/src/core/slack.ts +135 -0
  138. package/src/core/structure.ts +10 -5
  139. package/src/domain/architecture-config.ts +205 -1
  140. package/src/domain/architecture-error.ts +30 -0
  141. package/src/domain/facts.ts +9 -4
  142. package/src/domain/manifest-location.ts +41 -0
  143. package/src/domain/report.ts +203 -0
  144. package/src/domain/snapshot.ts +302 -0
  145. package/src/domain/violation.ts +4 -1
  146. package/src/index.ts +172 -3
  147. package/src/infrastructure/campaign-functions.ts +98 -0
  148. package/src/infrastructure/manifest-file.ts +204 -8
  149. package/src/infrastructure/manifest-include.ts +318 -0
  150. package/src/infrastructure/report-source-fake.ts +10 -0
  151. package/src/infrastructure/report-source-live.ts +192 -0
  152. package/src/infrastructure/syntax-matcher-fake.ts +51 -0
  153. package/src/infrastructure/walk.ts +70 -1
  154. package/src/load/policy.ts +193 -3
  155. package/src/manifest/compile.ts +290 -28
  156. package/src/manifest/expand.ts +183 -0
  157. package/src/manifest/infer.ts +643 -0
  158. package/src/manifest/json-schema.ts +168 -0
  159. package/src/manifest/manifest.ts +339 -11
  160. package/src/ports/campaign-predicate.ts +30 -0
  161. package/src/ports/language.ts +17 -0
  162. package/src/ports/report-source.ts +35 -0
  163. package/src/ports/syntax-matcher.ts +42 -0
  164. package/src/testing.ts +2 -0
@@ -1,7 +1,10 @@
1
1
  import * as Result from "effect/Result";
2
2
  import * as Schema from "effect/Schema";
3
- import { DeclarationKind, ResolveConfig } from "../domain/architecture-config.js";
3
+ import * as SchemaIssue from "effect/SchemaIssue";
4
+ import { CampaignUnit, DeclarationKind, ImportProbeTarget, ProbeDiagnostic, ReportFormat, ResolveConfig, } from "../domain/architecture-config.js";
4
5
  import { ConfigInvalid } from "../domain/architecture-error.js";
6
+ import { renderManifestPath, } from "../domain/manifest-location.js";
7
+ import { expandManifest, originOf } from "./expand.js";
5
8
  // A manifest is a tree of nodes keyed by path pattern, where everything the
6
9
  // architecture says about a part of the tree is written at that part of the tree.
7
10
  // A node is a folder (it has `children` and/or `files`) or a file (its key names
@@ -195,10 +198,183 @@ const CoverageFloors = Schema.Struct({
195
198
  surface: Schema.optionalKey(Schema.Finite),
196
199
  graph: Schema.optionalKey(Schema.Finite),
197
200
  });
201
+ // Ceilings on the conformance measures — what `architecture conformance`
202
+ // counts and `check` does not otherwise gate: the files no family reaches,
203
+ // the nodes no file is under, the allowances nothing imports through, and
204
+ // the fragment entries used at fewer than half the nodes granted them. Each
205
+ // is a count that only goes down: lowered when the number falls, never
206
+ // raised to make a red run green.
207
+ const ConformanceCeilings = Schema.Struct({
208
+ residue: Schema.optionalKey(Schema.Finite),
209
+ vacant: Schema.optionalKey(Schema.Finite),
210
+ slack: Schema.optionalKey(Schema.Finite),
211
+ concentration: Schema.optionalKey(Schema.Finite),
212
+ });
198
213
  const Limits = Schema.Struct({
199
214
  unrestricted: Schema.optionalKey(Schema.Finite),
200
215
  partial: Schema.optionalKey(Schema.Finite),
201
216
  coverage: Schema.optionalKey(CoverageFloors),
217
+ conformance: Schema.optionalKey(ConformanceCeilings),
218
+ });
219
+ // A campaign: a migration the repository is running, tracked as an object —
220
+ // a detector, a rationale, a guide, an owner, a definition of done, and a
221
+ // ledger of every place the pattern still occurs. Where a rule says what may
222
+ // never happen, a campaign names what the code is moving away from.
223
+ //
224
+ // The detector is a predicate algebra: `all`, `any` and `not` over leaf
225
+ // terms, the same three words ast-grep uses. Leaf terms reuse the other
226
+ // families' vocabularies where one exists.
227
+ // A regular expression over the whole repo-relative path, matched as the
228
+ // `structure` naming rules are: with `subject` and `convention`, the capture
229
+ // group named holds the name being judged, and the term holds when the name
230
+ // has the convention's shape.
231
+ const PathTerm = Schema.Struct({
232
+ file: Globs,
233
+ fileNot: Schema.optionalKey(Globs),
234
+ subject: Schema.optionalKey(Schema.Finite),
235
+ convention: Schema.optionalKey(SurfaceConvention),
236
+ });
237
+ // Holds when some import of the file resolves to the target — a path glob,
238
+ // `{ external: <package> }` or `{ builtin: <module> }` — and, with `symbols`,
239
+ // pulls one of those names across it.
240
+ const ImportsTerm = Schema.Struct({
241
+ resolves: ImportProbeTarget,
242
+ symbols: Schema.optionalKey(Schema.Array(Schema.String)),
243
+ });
244
+ // Holds for an export site the selectors admit — the `surface` selectors.
245
+ const ExportsTerm = Schema.Struct({
246
+ name: Schema.optionalKey(Globs),
247
+ kinds: Schema.optionalKey(Schema.Array(Schema.Literals(["named", "default", "namespace"]))),
248
+ declares: Schema.optionalKey(Schema.Array(DeclarationKind)),
249
+ reexport: Schema.optionalKey(Schema.Boolean),
250
+ });
251
+ // Holds for a member site the selectors admit — the `members` selectors.
252
+ const MembersTerm = Schema.Struct({
253
+ subject: Schema.Literals(["members", "calls"]),
254
+ name: Schema.optionalKey(Globs),
255
+ in: Schema.optionalKey(Globs),
256
+ declares: Schema.optionalKey(Schema.Array(DeclarationKind)),
257
+ });
258
+ // A regular expression over the file's text, multiline.
259
+ const ContentTerm = Schema.Struct({ regex: Schema.String });
260
+ // How a metavariable is narrowed: by the text it captured, or by what the
261
+ // identifier at its root is bound to — the module it resolves to and the
262
+ // name it was imported as (`member`), which is how `class $N extends $BASE`
263
+ // says "a React component" rather than "any class with a base".
264
+ const CaptureNarrowing = Schema.Struct({
265
+ regex: Schema.optionalKey(Schema.String),
266
+ binding: Schema.optionalKey(Schema.Struct({
267
+ resolves: ImportProbeTarget,
268
+ member: Schema.optionalKey(Schema.Array(Schema.String)),
269
+ })),
270
+ });
271
+ // An ast-grep rule object — `pattern`, `kind`, `regex`, `has`, `inside`,
272
+ // `precedes`, `follows`, `nthChild`, `all`, `any`, `not` — with `where`
273
+ // beside it. The rule is the engine's to validate; the manifest only knows
274
+ // which keys are a rule's and which is the narrowing. `kind` names are the
275
+ // engine's node kinds, which today are tree-sitter's.
276
+ const SyntaxTerm = Schema.Struct({
277
+ pattern: Schema.optionalKey(Schema.Unknown),
278
+ kind: Schema.optionalKey(Schema.Unknown),
279
+ regex: Schema.optionalKey(Schema.Unknown),
280
+ nthChild: Schema.optionalKey(Schema.Unknown),
281
+ inside: Schema.optionalKey(Schema.Unknown),
282
+ has: Schema.optionalKey(Schema.Unknown),
283
+ precedes: Schema.optionalKey(Schema.Unknown),
284
+ follows: Schema.optionalKey(Schema.Unknown),
285
+ all: Schema.optionalKey(Schema.Unknown),
286
+ any: Schema.optionalKey(Schema.Unknown),
287
+ not: Schema.optionalKey(Schema.Unknown),
288
+ where: Schema.optionalKey(Schema.Record(Schema.String, CaptureNarrowing)),
289
+ });
290
+ // One program to run or file to read, or several: a tool that takes one
291
+ // project at a time is run once per project, and the outputs are read as
292
+ // one report — a diagnostic two of them print is one diagnostic.
293
+ const ReportSources = Schema.Union([
294
+ Schema.String,
295
+ Schema.Array(Schema.String).check(Schema.isMinLength(1)),
296
+ ]);
297
+ // A finding of another program, read from the output of `command` (run
298
+ // from the repository root, once per `check`) or from `file` (written by
299
+ // an earlier step) in one of the known formats — `tsc`, `eslint --format
300
+ // json`, `oxlint --format json` — or by a `regex` with named groups. Holds
301
+ // for each diagnostic on the file whose code the term speaks to.
302
+ const ReportTerm = Schema.Struct({
303
+ command: Schema.optionalKey(ReportSources),
304
+ file: Schema.optionalKey(ReportSources),
305
+ format: ReportFormat,
306
+ pattern: Schema.optionalKey(Schema.String),
307
+ codes: Schema.optionalKey(Schema.Array(Schema.String)),
308
+ codesNot: Schema.optionalKey(Schema.Array(Schema.String)),
309
+ }).check(
310
+ // Refused at decode, where the issue names a line, rather than in the
311
+ // lowering: a term that names both sources or neither, and a `regex`
312
+ // term with nothing to match lines against.
313
+ Schema.makeFilter((term) => {
314
+ const issues = [];
315
+ if ((term.command === undefined) === (term.file === undefined)) {
316
+ issues.push("a report term names exactly one of `command` (a program to run) and `file` (a report already written)");
317
+ }
318
+ if (term.format === "regex" && term.pattern === undefined) {
319
+ issues.push({
320
+ path: ["pattern"],
321
+ issue: "a `regex` report term needs a `pattern` with named groups `file` and `line`",
322
+ });
323
+ }
324
+ return issues;
325
+ }));
326
+ // Each object carries exactly one term key, so a misspelled one is a decode
327
+ // error that names the line rather than a term quietly dropped.
328
+ const DetectorRef = Schema.suspend(() => DetectorSpec);
329
+ const DetectorSpec = Schema.Union([
330
+ Schema.Struct({ all: Schema.Array(DetectorRef) }),
331
+ Schema.Struct({ any: Schema.Array(DetectorRef) }),
332
+ Schema.Struct({ not: DetectorRef }),
333
+ Schema.Struct({ path: PathTerm }),
334
+ Schema.Struct({ imports: ImportsTerm }),
335
+ Schema.Struct({ exports: ExportsTerm }),
336
+ Schema.Struct({ members: MembersTerm }),
337
+ Schema.Struct({ requires: Schema.Array(Schema.String) }),
338
+ Schema.Struct({ content: ContentTerm }),
339
+ Schema.Struct({ syntax: SyntaxTerm }),
340
+ Schema.Struct({ report: ReportTerm }),
341
+ Schema.Struct({ fn: Schema.String }),
342
+ ]);
343
+ // A source the campaign is proven against at load. `path` alone proves a
344
+ // path-shaped detector; `source` is parsed, `edges` answers the `imports`
345
+ // term and a binding narrowing in place of the live resolver, `files`
346
+ // answers `requires` in place of the file system, and `report` answers a
347
+ // `report` term in place of running anything — one-based positions, as a
348
+ // tool prints them.
349
+ const CampaignProbe = Schema.Struct({
350
+ path: Schema.String,
351
+ source: Schema.optionalKey(Schema.String),
352
+ edges: Schema.optionalKey(Schema.Record(Schema.String, ImportProbeTarget)),
353
+ files: Schema.optionalKey(Schema.Array(Schema.String)),
354
+ report: Schema.optionalKey(Schema.Array(ProbeDiagnostic)),
355
+ });
356
+ // `30d`, `12h`: how long a campaign may go without progress before the
357
+ // conformance report calls it stalled.
358
+ const Duration = Schema.String.check(Schema.isPattern(/^\d+[dh]$/));
359
+ const Campaign = Schema.Struct({
360
+ // The ledger file's name, and the rule name's tail: `campaign/<id>`.
361
+ id: Schema.String.check(Schema.isPattern(/^[a-z0-9]+(?:-[a-z0-9]+)*$/)),
362
+ title: Schema.optionalKey(Schema.String),
363
+ why: Schema.String,
364
+ // What a reader at a hit does about it — the message every hit carries.
365
+ how: Schema.String,
366
+ owner: Schema.optionalKey(Schema.String),
367
+ // Which files the campaign selects. Alias-aware globs, as the graph rules
368
+ // take; a campaign's reach is its scope, so it joins no coverage row.
369
+ scope: Globs,
370
+ unit: CampaignUnit,
371
+ detect: DetectorSpec,
372
+ probes: Schema.Struct({
373
+ fires: Schema.Array(CampaignProbe),
374
+ ignores: Schema.optionalKey(Schema.Array(CampaignProbe)),
375
+ }),
376
+ staleAfter: Duration,
377
+ onComplete: Schema.optionalKey(Schema.Literals(["keep", "remove"])),
202
378
  });
203
379
  export const Manifest = Schema.Struct({
204
380
  // How an import specifier becomes a file. Every pattern below is matched
@@ -214,13 +390,28 @@ export const Manifest = Schema.Struct({
214
390
  exports: Schema.optionalKey(Schema.Array(ExportRestriction)),
215
391
  graph: Schema.optionalKey(Graph),
216
392
  limits: Schema.optionalKey(Limits),
393
+ campaigns: Schema.optionalKey(Schema.Array(Campaign)),
394
+ // Where each campaign's ledger is written: `<ledger>/<id>.json`, relative
395
+ // to the manifest. Defaults to `.architecture-campaigns`.
396
+ ledger: Schema.optionalKey(Schema.String),
217
397
  // Shorthands expanded in every glob, so a pattern reads the way the repo's own
218
398
  // imports do rather than repeating `packages/server/src` on every line.
219
399
  aliases: Schema.optionalKey(Schema.Record(Schema.String, Schema.String)),
220
400
  tree: Schema.Record(Schema.String, ManifestNodeSchema),
221
401
  });
402
+ export const DEFAULT_LEDGER_DIR = ".architecture-campaigns";
403
+ // `30d` → milliseconds. The schema has already refused any other shape.
404
+ export const durationMs = (duration) => {
405
+ const amount = Number(duration.slice(0, -1));
406
+ return amount * (duration.endsWith("h") ? 3_600_000 : 86_400_000);
407
+ };
222
408
  export const globsOf = (globs) => typeof globs === "string" ? [globs] : globs;
223
- const decode = Schema.decodeUnknownResult(Manifest);
409
+ // Every issue, not the first: a manifest is edited by hand, and the reader
410
+ // fixing one line wants to know about the other three. A key the schema does
411
+ // not declare is refused rather than dropped — a misspelled `matchNot` that
412
+ // decoded to nothing would be a rule quietly enforcing less than it says.
413
+ const decode = Schema.decodeUnknownResult(Manifest, { errors: "all", onExcessProperty: "error" });
414
+ const flatten = SchemaIssue.makeFormatterStandardSchemaV1();
224
415
  const isRecord = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
225
416
  const isList = (value) => Array.isArray(value);
226
417
  // The three resolver options that used to sit on `resolve` itself, when every
@@ -295,9 +486,56 @@ const normalizeLegacyMembers = (input) => {
295
486
  const tree = Object.fromEntries(Object.entries(input.tree).map(([key, value]) => [key, node(key, value)]));
296
487
  return { input: { ...input, tree }, notices };
297
488
  };
298
- export const decodeManifest = (configPath, input) => {
299
- const resolve = normalizeLegacyResolve(input);
489
+ const fileLabelOf = (configPath) => configPath.split(/[\\/]/).at(-1) ?? configPath;
490
+ // A position carries its own file when the value was written in a file the
491
+ // manifest `include`d; otherwise it is in the manifest file itself.
492
+ const positionOf = (file, locate, path) => {
493
+ const found = locate?.(path) ?? null;
494
+ return found === null
495
+ ? null
496
+ : `${found.file ?? file}:${String(found.line)}:${String(found.column)}`;
497
+ };
498
+ // One line per issue: where in the file, which path, what was wrong — and,
499
+ // when the value came in through a `use`, the reference that pulled it in,
500
+ // since the fragment's own line may sit far from where the reader is looking.
501
+ const describeIssue = (configPath, locate, substitutions, path, detail) => {
502
+ const file = fileLabelOf(configPath);
503
+ const origin = originOf(substitutions, path);
504
+ const at = positionOf(file, locate, origin.path);
505
+ const via = origin.via.map(({ at: ref, name }) => {
506
+ const position = positionOf(file, locate, ref);
507
+ return `via \`use: ${JSON.stringify(name)}\`${position === null ? "" : ` at ${position}`}`;
508
+ });
509
+ return (` ${at === null ? "" : `${at} `}${renderManifestPath(origin.path)}: ${detail}` +
510
+ (via.length === 0 ? "" : ` (${via.join(", ")})`));
511
+ };
512
+ // The standard-schema formatter flattens the issue tree to `{ path, message }`
513
+ // pairs; a path segment may arrive wrapped as `{ key }`.
514
+ const pathOf = (issue) => (issue.path ?? []).map((segment) => (typeof segment === "object" ? segment.key : segment));
515
+ export const decodeManifest = (configPath, input, options = {}) => {
516
+ const expanded = expandManifest(input);
517
+ if (Result.isFailure(expanded)) {
518
+ return Result.fail(new ConfigInvalid({
519
+ configPath,
520
+ detail: "the manifest does not expand:\n" +
521
+ describeIssue(configPath, options.locate, [], expanded.failure.path, expanded.failure.detail),
522
+ }));
523
+ }
524
+ const { substitutions, value } = expanded.success;
525
+ const resolve = normalizeLegacyResolve(value);
300
526
  const members = normalizeLegacyMembers(resolve.input);
301
- return Result.map(Result.mapError(decode(members.input), (issue) => new ConfigInvalid({ configPath, detail: String(issue) })), (manifest) => ({ manifest, notices: [...resolve.notices, ...members.notices] }));
527
+ const decoded = decode(members.input);
528
+ if (Result.isFailure(decoded)) {
529
+ const lines = flatten(decoded.failure.issue).issues.map((issue) => describeIssue(configPath, options.locate, substitutions, pathOf(issue), issue.message));
530
+ return Result.fail(new ConfigInvalid({
531
+ configPath,
532
+ detail: `the manifest does not decode:\n${lines.join("\n")}`,
533
+ }));
534
+ }
535
+ return Result.succeed({
536
+ manifest: decoded.success,
537
+ notices: [...resolve.notices, ...members.notices],
538
+ substitutions,
539
+ });
302
540
  };
303
541
  //# sourceMappingURL=manifest.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"manifest.js","sourceRoot":"","sources":["../../../src/manifest/manifest.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAExC,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,kCAAkC,CAAC;AAClF,OAAO,EAAE,aAAa,EAAE,MAAM,iCAAiC,CAAC;AAEhE,4EAA4E;AAC5E,kFAAkF;AAClF,iFAAiF;AACjF,uBAAuB;AACvB,EAAE;AACF,+EAA+E;AAC/E,gFAAgF;AAChF,6BAA6B;AAE7B,MAAM,KAAK,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;AAEzE,4EAA4E;AAC5E,iFAAiF;AACjF,8EAA8E;AAC9E,MAAM,MAAM,GAAG,MAAM,CAAC,MAAM,CAAC;IAC3B,KAAK,EAAE,KAAK;IACZ,QAAQ,EAAE,MAAM,CAAC,WAAW,CAAC,KAAK,CAAC;IACnC,MAAM,EAAE,MAAM,CAAC,WAAW,CAAC,KAAK,CAAC;IACjC,OAAO,EAAE,MAAM,CAAC,MAAM;CACvB,CAAC,CAAC;AAEH,kDAAkD;AAClD,MAAM,OAAO,GAAG,MAAM,CAAC,MAAM,CAAC;IAC5B,OAAO,EAAE,MAAM,CAAC,WAAW,CAA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AC,OAAO,CAAC;IAElD,MAAM,OAAO,GAAG,sBAAsB,CAAC,KAAK,CAAC,CAAC;IAC9C,MAAM,OAAO,GAAG,sBAAsB,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IACtD,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IACtC,IAAI,MAAM,CAAC,SAAS,CAAC,OAAO,CAAC,EAAE,CAAC;QAC9B,MAAM,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAChE,aAAa,CAAC,UAAU,EAAE,OAAO,CAAC,MAAM,EAAE,aAAa,EAAE,MAAM,CAAC,KAAK,CAAC,EAAE,KAAK,CAAC,OAAO,CAAC,CACvF,CAAC;QACF,OAAO,MAAM,CAAC,IAAI,CAChB,IAAI,aAAa,CAAC;YAChB,UAAU;YACV,MAAM,EAAE,kCAAkC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE;SAC7D,CAAC,CACH,CAAC;IACJ,CAAC;IACD,OAAO,MAAM,CAAC,OAAO,CAAC;QACpB,QAAQ,EAAE,OAAO,CAAC,OAAO;QACzB,OAAO,EAAE,CAAC,GAAG,OAAO,CAAC,OAAO,EAAE,GAAG,OAAO,CAAC,OAAO,CAAC;QACjD,aAAa;KACd,CAAC,CAAC;AACL,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=campaign-predicate.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"campaign-predicate.js","sourceRoot":"","sources":["../../../src/ports/campaign-predicate.ts"],"names":[],"mappings":""}
@@ -0,0 +1,7 @@
1
+ // The commands or files a spec names, as a list.
2
+ export const reportSourcesOf = (spec) => {
3
+ const named = spec.command ?? spec.file ?? [];
4
+ return typeof named === "string" ? [named] : named;
5
+ };
6
+ export const NO_REPORTS = { diagnosticsOf: () => [] };
7
+ //# sourceMappingURL=report-source.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"report-source.js","sourceRoot":"","sources":["../../../src/ports/report-source.ts"],"names":[],"mappings":"AAaA,iDAAiD;AACjD,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,IAAgB,EAAyB,EAAE;IACzE,MAAM,KAAK,GAAG,IAAI,CAAC,OAAO,IAAI,IAAI,CAAC,IAAI,IAAI,EAAE,CAAC;IAC9C,OAAO,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC;AACrD,CAAC,CAAC;AAiBF,MAAM,CAAC,MAAM,UAAU,GAAiB,EAAE,aAAa,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE,CAAC"}
@@ -0,0 +1,12 @@
1
+ // A campaign's `syntax` term asks a question the facts cannot answer: does
2
+ // this file contain an expression of this shape? A syntax matcher parses one
3
+ // file and finds every node matching a rule, returning the matched text, what
4
+ // each metavariable captured, where it sits, and the named declaration it
5
+ // sits in. The rule object is the engine's own — ast-grep's, for the one
6
+ // matcher that exists — and is carried opaquely; the matcher validates it.
7
+ //
8
+ // The matcher knows nothing about imports. Narrowing a capture by what its
9
+ // identifier is bound to is done in the core, against the file's facts and
10
+ // the resolver, so a second engine has only this port to implement.
11
+ export {};
12
+ //# sourceMappingURL=syntax-matcher.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"syntax-matcher.js","sourceRoot":"","sources":["../../../src/ports/syntax-matcher.ts"],"names":[],"mappings":"AAAA,2EAA2E;AAC3E,6EAA6E;AAC7E,8EAA8E;AAC9E,0EAA0E;AAC1E,yEAAyE;AACzE,2EAA2E;AAC3E,EAAE;AACF,2EAA2E;AAC3E,2EAA2E;AAC3E,oEAAoE"}
@@ -4,4 +4,6 @@
4
4
  export { makeFactExtractorFake } from "./infrastructure/fact-extractor-fake.js";
5
5
  export { makeFileSystemFake } from "./infrastructure/file-system-fake.js";
6
6
  export { makeModuleResolverFake } from "./infrastructure/module-resolver-fake.js";
7
+ export { makeReportSourceFake } from "./infrastructure/report-source-fake.js";
8
+ export { makeSyntaxMatcherFake } from "./infrastructure/syntax-matcher-fake.js";
7
9
  //# sourceMappingURL=testing.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"testing.js","sourceRoot":"","sources":["../../src/testing.ts"],"names":[],"mappings":"AAAA,6EAA6E;AAC7E,4EAA4E;AAC5E,0CAA0C;AAC1C,OAAO,EAAE,qBAAqB,EAAE,MAAM,yCAAyC,CAAC;AAChF,OAAO,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAC;AAC1E,OAAO,EAAE,sBAAsB,EAAE,MAAM,0CAA0C,CAAC"}
1
+ {"version":3,"file":"testing.js","sourceRoot":"","sources":["../../src/testing.ts"],"names":[],"mappings":"AAAA,6EAA6E;AAC7E,4EAA4E;AAC5E,0CAA0C;AAC1C,OAAO,EAAE,qBAAqB,EAAE,MAAM,yCAAyC,CAAC;AAChF,OAAO,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAC;AAC1E,OAAO,EAAE,sBAAsB,EAAE,MAAM,0CAA0C,CAAC;AAClF,OAAO,EAAE,oBAAoB,EAAE,MAAM,wCAAwC,CAAC;AAC9E,OAAO,EAAE,qBAAqB,EAAoB,MAAM,yCAAyC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@goodbones/core",
3
- "version": "0.1.0-beta.1",
3
+ "version": "0.1.0-beta.10",
4
4
  "type": "module",
5
5
  "license": "MIT",
6
6
  "description": "Architecture policy as one manifest of your repository, language-agnostic: the manifest schema, the evaluators for imports, exports, members, surface, structure and the import graph, the ports a language pack implements, and the loader that turns a manifest into a policy every rule of which has proven it can fire.",
@@ -33,20 +33,26 @@
33
33
  "types": "./build/dts/testing.d.ts",
34
34
  "default": "./build/esm/testing.js"
35
35
  },
36
+ "./schema/architecture.schema.json": "./schema/architecture.schema.json",
37
+ "./schema/architecture-node.schema.json": "./schema/architecture-node.schema.json",
38
+ "./schema/conformance.schema.json": "./schema/conformance.schema.json",
36
39
  "./package.json": "./package.json"
37
40
  },
38
41
  "types": "./build/dts/index.d.ts",
39
42
  "files": [
40
43
  "build/dts",
41
44
  "build/esm",
45
+ "schema",
42
46
  "src",
43
47
  "!src/**/*.test.ts"
44
48
  ],
45
49
  "dependencies": {
46
- "effect": "4.0.0-beta.94"
50
+ "effect": "4.0.0-beta.94",
51
+ "yaml": "^2.9.0"
47
52
  },
48
53
  "devDependencies": {
49
- "@types/node": "^25.9.4"
54
+ "@types/node": "^25.9.4",
55
+ "ajv": "^8.20.0"
50
56
  },
51
57
  "nx": {
52
58
  "includedScripts": []