@metaobjectsdev/cli 1.0.2 → 1.0.4-rc.1
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/README.md +13 -5
- package/dist/src/commands/deps.d.ts +3 -0
- package/dist/src/commands/deps.d.ts.map +1 -0
- package/dist/src/commands/deps.js +200 -0
- package/dist/src/commands/deps.js.map +1 -0
- package/dist/src/commands/docs.d.ts.map +1 -1
- package/dist/src/commands/docs.js +19 -3
- package/dist/src/commands/docs.js.map +1 -1
- package/dist/src/commands/eject.d.ts +2 -1
- package/dist/src/commands/eject.d.ts.map +1 -1
- package/dist/src/commands/eject.js +235 -75
- package/dist/src/commands/eject.js.map +1 -1
- package/dist/src/commands/gen.d.ts.map +1 -1
- package/dist/src/commands/gen.js +173 -30
- package/dist/src/commands/gen.js.map +1 -1
- package/dist/src/commands/init.d.ts +5 -9
- package/dist/src/commands/init.d.ts.map +1 -1
- package/dist/src/commands/init.js +92 -402
- package/dist/src/commands/init.js.map +1 -1
- package/dist/src/commands/migrate.d.ts.map +1 -1
- package/dist/src/commands/migrate.js +24 -19
- package/dist/src/commands/migrate.js.map +1 -1
- package/dist/src/commands/prompt-snapshot.d.ts.map +1 -1
- package/dist/src/commands/prompt-snapshot.js +2 -1
- package/dist/src/commands/prompt-snapshot.js.map +1 -1
- package/dist/src/commands/verify.d.ts.map +1 -1
- package/dist/src/commands/verify.js +186 -29
- package/dist/src/commands/verify.js.map +1 -1
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +97 -15
- package/dist/src/index.js.map +1 -1
- package/dist/src/lib/advisory.d.ts +6 -0
- package/dist/src/lib/advisory.d.ts.map +1 -1
- package/dist/src/lib/advisory.js +10 -0
- package/dist/src/lib/advisory.js.map +1 -1
- package/dist/src/lib/agent-context-staleness.d.ts.map +1 -1
- package/dist/src/lib/agent-context-staleness.js +7 -1
- package/dist/src/lib/agent-context-staleness.js.map +1 -1
- package/dist/src/lib/args.d.ts +75 -3
- package/dist/src/lib/args.d.ts.map +1 -1
- package/dist/src/lib/args.js +54 -5
- package/dist/src/lib/args.js.map +1 -1
- package/dist/src/lib/catalog-listing.d.ts +92 -0
- package/dist/src/lib/catalog-listing.d.ts.map +1 -0
- package/dist/src/lib/catalog-listing.js +268 -0
- package/dist/src/lib/catalog-listing.js.map +1 -0
- package/dist/src/lib/catalog.d.ts +41 -0
- package/dist/src/lib/catalog.d.ts.map +1 -0
- package/dist/src/lib/catalog.js +89 -0
- package/dist/src/lib/catalog.js.map +1 -0
- package/dist/src/lib/collection-load-options.d.ts +13 -0
- package/dist/src/lib/collection-load-options.d.ts.map +1 -0
- package/dist/src/lib/collection-load-options.js +25 -0
- package/dist/src/lib/collection-load-options.js.map +1 -0
- package/dist/src/lib/dependency-sync.d.ts +170 -0
- package/dist/src/lib/dependency-sync.d.ts.map +1 -0
- package/dist/src/lib/dependency-sync.js +457 -0
- package/dist/src/lib/dependency-sync.js.map +1 -0
- package/dist/src/lib/install-set.d.ts +31 -0
- package/dist/src/lib/install-set.d.ts.map +1 -0
- package/dist/src/lib/install-set.js +103 -0
- package/dist/src/lib/install-set.js.map +1 -0
- package/dist/src/lib/library-eject.d.ts +79 -0
- package/dist/src/lib/library-eject.d.ts.map +1 -0
- package/dist/src/lib/library-eject.js +241 -0
- package/dist/src/lib/library-eject.js.map +1 -0
- package/dist/src/lib/library-listing.d.ts +63 -0
- package/dist/src/lib/library-listing.d.ts.map +1 -0
- package/dist/src/lib/library-listing.js +178 -0
- package/dist/src/lib/library-listing.js.map +1 -0
- package/dist/src/lib/library-prefix-advisory.d.ts +17 -0
- package/dist/src/lib/library-prefix-advisory.d.ts.map +1 -0
- package/dist/src/lib/library-prefix-advisory.js +67 -0
- package/dist/src/lib/library-prefix-advisory.js.map +1 -0
- package/dist/src/lib/load-metaobjects-config.d.ts +1 -2
- package/dist/src/lib/load-metaobjects-config.d.ts.map +1 -1
- package/dist/src/lib/load-metaobjects-config.js +11 -17
- package/dist/src/lib/load-metaobjects-config.js.map +1 -1
- package/dist/src/lib/migrate-scope.d.ts +32 -1
- package/dist/src/lib/migrate-scope.d.ts.map +1 -1
- package/dist/src/lib/migrate-scope.js +51 -3
- package/dist/src/lib/migrate-scope.js.map +1 -1
- package/dist/src/lib/overlay-lint.d.ts +37 -0
- package/dist/src/lib/overlay-lint.d.ts.map +1 -0
- package/dist/src/lib/overlay-lint.js +102 -0
- package/dist/src/lib/overlay-lint.js.map +1 -0
- package/dist/src/lib/requirement-check.d.ts +26 -3
- package/dist/src/lib/requirement-check.d.ts.map +1 -1
- package/dist/src/lib/requirement-check.js +71 -13
- package/dist/src/lib/requirement-check.js.map +1 -1
- package/package.json +10 -10
- package/src/commands/deps.ts +231 -0
- package/src/commands/docs.ts +19 -3
- package/src/commands/eject.ts +304 -90
- package/src/commands/gen.ts +189 -29
- package/src/commands/init.ts +95 -407
- package/src/commands/migrate.ts +26 -16
- package/src/commands/prompt-snapshot.ts +2 -1
- package/src/commands/verify.ts +213 -30
- package/src/index.ts +97 -15
- package/src/lib/advisory.ts +13 -0
- package/src/lib/agent-context-staleness.ts +7 -1
- package/src/lib/args.ts +118 -8
- package/src/lib/catalog-listing.ts +369 -0
- package/src/lib/catalog.ts +107 -0
- package/src/lib/collection-load-options.ts +42 -0
- package/src/lib/dependency-sync.ts +656 -0
- package/src/lib/install-set.ts +116 -0
- package/src/lib/library-eject.ts +298 -0
- package/src/lib/library-listing.ts +258 -0
- package/src/lib/library-prefix-advisory.ts +78 -0
- package/src/lib/load-metaobjects-config.ts +15 -21
- package/src/lib/migrate-scope.ts +59 -4
- package/src/lib/overlay-lint.ts +129 -0
- package/src/lib/requirement-check.ts +100 -14
package/dist/src/index.js
CHANGED
|
@@ -14,7 +14,7 @@ const VERSION = cliVersion();
|
|
|
14
14
|
* human text. It is named ONCE and used by both the warning below and the help
|
|
15
15
|
* text above, so the two cannot drift apart.
|
|
16
16
|
*/
|
|
17
|
-
const FORMAT_AWARE_COMMANDS = ["gen", "verify", "migrate", "types"];
|
|
17
|
+
const FORMAT_AWARE_COMMANDS = ["gen", "verify", "migrate", "types", "deps", "eject"];
|
|
18
18
|
const HELP_TEXT = `meta — MetaObjects CLI (v${VERSION})
|
|
19
19
|
|
|
20
20
|
USAGE:
|
|
@@ -28,10 +28,13 @@ COMMANDS:
|
|
|
28
28
|
gen [<entity>...] Codegen TS targets from your declared metadata
|
|
29
29
|
eject <generator> Copy a reference generator into codegen/generators/ to own it (any time after init)
|
|
30
30
|
eject --list List every ejectable generator name, grouped by package
|
|
31
|
+
deps sync [<name>...] Resolve declared dependencies (path transport): sync the committed
|
|
32
|
+
snapshot + sha256 lock (.metaobjects/deps/, .metaobjects/deps.lock.json)
|
|
33
|
+
deps list One line per locked dependency: name, version, hash, node/package summary
|
|
31
34
|
types [query] Search the metadata vocabulary (types, subtypes, @attrs) by name or description
|
|
32
35
|
export Flatten loaded metadata to one canonical JSON artifact
|
|
33
36
|
docs [<project-root>] --out <dir> Generate neutral metadata documentation (entity + template pages; --site for HTML site)
|
|
34
|
-
verify Drift gate — subverbs: --templates / --db / --codegen / --docs (bare = --templates)
|
|
37
|
+
verify Drift gate — subverbs: --templates / --db / --codegen / --docs / --deps (bare = --templates)
|
|
35
38
|
upgrade Rewrite retired metadata vocabulary (previews; --apply writes)
|
|
36
39
|
prompt-snapshot Snapshot rendered template.* output; --check gates drift
|
|
37
40
|
migrate Diff metadata vs live DB; emit migration SQL files
|
|
@@ -51,8 +54,14 @@ GLOBAL OPTIONS:
|
|
|
51
54
|
|
|
52
55
|
GEN FLAGS:
|
|
53
56
|
--dry-run Compute and print, don't write
|
|
54
|
-
--list Print the generator
|
|
55
|
-
|
|
57
|
+
--list Print the generator CATALOG (name, layer, tier, what it emits,
|
|
58
|
+
what to install) and exit. Codegen is opt-in: nothing runs until
|
|
59
|
+
you wire it, and this is where you choose. No config or metadata
|
|
60
|
+
required — add --format json for the same catalog, machine-readable.
|
|
61
|
+
--probe With --list: construct every catalog generator and dry-run it
|
|
62
|
+
against YOUR model, reporting how many files each would emit.
|
|
63
|
+
A count per generator beats any category label — and it
|
|
64
|
+
cannot go stale, because it runs the generators. Needs a project.
|
|
56
65
|
--baseline <default|adopt|fresh>
|
|
57
66
|
First-time-on-existing-file behavior. Default: refuse a file that
|
|
58
67
|
cannot be proved to be generated output. "adopt" records the files
|
|
@@ -90,6 +99,10 @@ VERIFY FLAGS (ADR-0021 D2 — explicit subverbs; combine any; exit 1 on ANY drif
|
|
|
90
99
|
run would emit; never reports an extra file, because docs.outDir
|
|
91
100
|
holds hand-written documentation MetaObjects did not write.
|
|
92
101
|
Needs metaobjects.config.ts; exit 2 if absent.
|
|
102
|
+
--deps Dependency drift — re-resolve each declared dependency and compare
|
|
103
|
+
its installed artifact's hash against .metaobjects/deps.lock.json
|
|
104
|
+
(the same check 'meta deps check' runs). Never part of the bare-verify
|
|
105
|
+
default — it needs the publisher reachable, which CI may not have.
|
|
93
106
|
--db <url> Schema drift — live DB URL enables the schema-drift gate.
|
|
94
107
|
Supports: file:, libsql:, postgres:, postgresql:. Omit to skip.
|
|
95
108
|
D1 has no URL — use --dialect d1 / --d1 <binding> instead.
|
|
@@ -104,6 +117,8 @@ VERIFY FLAGS (ADR-0021 D2 — explicit subverbs; combine any; exit 1 on ANY drif
|
|
|
104
117
|
--no-antipatterns Suppress the advisory "you hand-rolled what MetaObjects can
|
|
105
118
|
model" pass (aggregate/currency/enum hints; warnings only)
|
|
106
119
|
--no-requirement-lint Suppress the advisory requirement AUTHORING lint (not the gate)
|
|
120
|
+
--no-overlay-lint Suppress the advisory overlay-redeclaration AUTHORING lint
|
|
121
|
+
(never a gate — this lint can't fail the build)
|
|
107
122
|
--limit <n|all> How many advisory lines TEXT output prints per section before
|
|
108
123
|
it truncates (default 20). Never applies to --format
|
|
109
124
|
toon/json, which carry every finding and every diagnostic.
|
|
@@ -142,8 +157,14 @@ USAGE:
|
|
|
142
157
|
|
|
143
158
|
FLAGS:
|
|
144
159
|
--dry-run Compute and print, don't write
|
|
145
|
-
--list Print the generator
|
|
146
|
-
|
|
160
|
+
--list Print the generator CATALOG (name, layer, tier, what it emits,
|
|
161
|
+
what to install) and exit. Codegen is opt-in: nothing runs until
|
|
162
|
+
you wire it, and this is where you choose. No config or metadata
|
|
163
|
+
required — add --format json for the same catalog, machine-readable.
|
|
164
|
+
--probe With --list: construct every catalog generator and dry-run it
|
|
165
|
+
against YOUR model, reporting how many files each would emit.
|
|
166
|
+
A count per generator beats any category label — and it cannot go
|
|
167
|
+
stale, because it runs the generators. Needs a project.
|
|
147
168
|
--baseline <default|adopt|fresh>
|
|
148
169
|
First-time-on-existing-file behavior. Default: refuse a file that
|
|
149
170
|
cannot be proved to be generated output. "adopt" records the files
|
|
@@ -169,23 +190,65 @@ limit on the machine-readable result.
|
|
|
169
190
|
|
|
170
191
|
NOTE: outDir, dialect, dbImport, extStyle are read from metaobjects.config.ts
|
|
171
192
|
`,
|
|
172
|
-
eject: `meta eject — copy
|
|
193
|
+
eject: `meta eject — copy reference generators into your repo so you own them
|
|
173
194
|
|
|
174
195
|
USAGE:
|
|
175
|
-
meta eject <name
|
|
196
|
+
meta eject <name>... Copy each generator into codegen/generators/<name>.ts
|
|
176
197
|
meta eject --list List every ejectable generator name, grouped by package
|
|
177
198
|
|
|
199
|
+
Codegen is opt-in — \`meta init\` wires nothing — so this is the door every generator
|
|
200
|
+
you run comes through. Take several at once: the install set is CONSOLIDATED, so
|
|
201
|
+
\`meta eject form hooks grid\` prints one install line, not three. An unknown name
|
|
202
|
+
refuses the whole call and copies nothing.
|
|
203
|
+
|
|
178
204
|
FLAGS:
|
|
179
205
|
--list List ejectable generators instead of copying one
|
|
180
206
|
--force Overwrite an already-ejected file (default: never clobber)
|
|
207
|
+
--format <toon|json|text> Output format (global flag). The structured form carries
|
|
208
|
+
each file's wire lines, the consolidated install set and the
|
|
209
|
+
config keys the ejected generators read.
|
|
181
210
|
--help, -h Print this help
|
|
182
211
|
|
|
183
|
-
\`meta init\` copies
|
|
184
|
-
|
|
185
|
-
the
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
212
|
+
\`meta init\` copies NO generators — codegen is opt-in, and codegen/generators/
|
|
213
|
+
starts empty on purpose. Everything you run comes through here (ADR-0034
|
|
214
|
+
scaffold-and-own): the file is YOURS to edit, and \`meta gen\` runs your copy, not
|
|
215
|
+
the package's. It prints the import line and the entry to add in
|
|
216
|
+
metaobjects.config.ts, and never overwrites a file you already own without --force.
|
|
217
|
+
|
|
218
|
+
Find names with \`meta gen --list\` — add --probe to see how many files each would
|
|
219
|
+
emit for your model.
|
|
220
|
+
`,
|
|
221
|
+
deps: `meta deps — sync a declared metadata dependency's committed snapshot
|
|
222
|
+
|
|
223
|
+
USAGE:
|
|
224
|
+
meta deps sync [<name>...] Resolve each declared dependency (path transport only in
|
|
225
|
+
this release — npm/python refuse by name), validate its
|
|
226
|
+
manifest + artifact, copy it into .metaobjects/deps/<name>/,
|
|
227
|
+
and pin it in .metaobjects/deps.lock.json. Naming one or more
|
|
228
|
+
<name>s syncs only those; bare 'sync' syncs everything
|
|
229
|
+
declared. A dependency removed from config is PRUNED from
|
|
230
|
+
the lock and its snapshot dir deleted, every run.
|
|
231
|
+
meta deps list One line per locked dependency: name, version, hash8,
|
|
232
|
+
node count, packages.
|
|
233
|
+
meta deps check Re-resolve each declared dependency (path transport, same
|
|
234
|
+
as sync steps 1-2) and compare its INSTALLED artifact's hash
|
|
235
|
+
against .metaobjects/deps.lock.json. Read-only — never
|
|
236
|
+
touches the lock or the snapshot. Exits 1 if any dependency
|
|
237
|
+
has drifted or cannot be resolved (ERR_DEPENDENCY_UPSTREAM_DRIFT).
|
|
238
|
+
|
|
239
|
+
FLAGS:
|
|
240
|
+
--dry-run Plan and report; write nothing (sync only)
|
|
241
|
+
--format <toon|json|text> Output format (global flag; default toon off-TTY)
|
|
242
|
+
--help, -h Print this help
|
|
243
|
+
|
|
244
|
+
Only the "path" transport resolves in this release — a "npm"/"python" dependency spec is
|
|
245
|
+
valid config (reserved for a future toolchain) but 'meta deps sync' refuses it by name:
|
|
246
|
+
"transport \`npm\` is not supported by this toolchain yet; use \`path\`".
|
|
247
|
+
|
|
248
|
+
The lock is the ONLY thing 'meta deps sync' writes to besides the snapshot directory —
|
|
249
|
+
sync never touches your own metadata files. 'meta deps check' compares the lock against
|
|
250
|
+
what is installed right now (the same check 'meta verify --deps' runs); 'meta deps sync'
|
|
251
|
+
only ever compares against what config DECLARES.
|
|
189
252
|
`,
|
|
190
253
|
verify: `meta verify — drift gate (templates / DB schema / codegen / migration replay)
|
|
191
254
|
|
|
@@ -205,6 +268,12 @@ FLAGS:
|
|
|
205
268
|
a namespace MetaObjects owns); the count of exempt pages is
|
|
206
269
|
reported either way, and a run where every page is ignored is
|
|
207
270
|
refused rather than reported clean.
|
|
271
|
+
--deps Dependency drift — re-resolve each declared dependency exactly as
|
|
272
|
+
'meta deps check' does and compare its installed artifact's hash
|
|
273
|
+
against .metaobjects/deps.lock.json. Exits 1 if any dependency has
|
|
274
|
+
drifted or cannot be resolved (ERR_DEPENDENCY_UPSTREAM_DRIFT). NEVER
|
|
275
|
+
part of the bare-verify default — it needs the publisher reachable,
|
|
276
|
+
which CI may not have.
|
|
208
277
|
--db <url> Schema drift — live DB URL enables the schema-drift gate.
|
|
209
278
|
Supports: file:, libsql:, postgres:, postgresql:
|
|
210
279
|
D1 has no URL — use --dialect d1 / --d1 <binding> instead.
|
|
@@ -232,6 +301,8 @@ FLAGS:
|
|
|
232
301
|
migrating a model onto a registered provider.
|
|
233
302
|
--no-antipatterns Suppress the advisory "hand-rolled what MetaObjects can model" pass
|
|
234
303
|
--no-requirement-lint Suppress the advisory requirement AUTHORING lint (not the gate)
|
|
304
|
+
--no-overlay-lint Suppress the advisory overlay-redeclaration AUTHORING lint —
|
|
305
|
+
never a gate; this lint can't fail the build
|
|
235
306
|
--limit <n|all> Advisory lines TEXT output prints PER SECTION before truncating
|
|
236
307
|
(default 20; per-section so the authoring lint can never push
|
|
237
308
|
the gate's own warnings off the end)
|
|
@@ -253,6 +324,13 @@ lint in its own section: names that are not addressable, prose slots holding one
|
|
|
253
324
|
sentence twice, content written where no surface reads it. Warnings only — it can
|
|
254
325
|
never fail the build. Opt out with --no-requirement-lint or META_NO_REQUIREMENT_LINT=1.
|
|
255
326
|
The requirements GATE itself (dangling refs, link floor, levels) always runs.
|
|
327
|
+
|
|
328
|
+
verify also prints an ADVISORY overlay authoring lint, in its own section: a
|
|
329
|
+
top-level declaration redeclared in two or more files where more than one
|
|
330
|
+
redeclaration lacks 'overlay: true' — today's default merge rule reuses it
|
|
331
|
+
silently, but the same unflagged redeclaration silently becomes a NEW object
|
|
332
|
+
the day the target is renamed or removed upstream. Warnings only — it can
|
|
333
|
+
never fail the build. Opt out with --no-overlay-lint or META_NO_OVERLAY_LINT=1.
|
|
256
334
|
`,
|
|
257
335
|
export: `meta export — flatten loaded metadata to one canonical JSON artifact
|
|
258
336
|
|
|
@@ -514,7 +592,11 @@ export async function run(argv) {
|
|
|
514
592
|
}
|
|
515
593
|
case "eject": {
|
|
516
594
|
const { ejectCommand } = await import("./commands/eject.js");
|
|
517
|
-
return ejectCommand(rest, cwd);
|
|
595
|
+
return ejectCommand(rest, cwd, fmt);
|
|
596
|
+
}
|
|
597
|
+
case "deps": {
|
|
598
|
+
const { depsCommand } = await import("./commands/deps.js");
|
|
599
|
+
return depsCommand(rest, cwd, fmt);
|
|
518
600
|
}
|
|
519
601
|
case "export": {
|
|
520
602
|
const { exportCommand } = await import("./commands/export.js");
|
package/dist/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,GAAG,EAAE,MAAM,cAAc,CAAC;AACnC,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,aAAa,EAAE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AC;YAC3D,OAAO,WAAW,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC;QAChC,CAAC;QACD,KAAK,QAAQ,CAAC,CAAC,CAAC;YACd,MAAM,EAAE,aAAa,EAAE,GAAG,MAAM,MAAM,CAAC,sBAAsB,CAAC,CAAC;YAC/D,OAAO,aAAa,CAAC,IAAI,EAAE,GAAG,EAAE,SAAS,EAAE,GAAG,CAAC,CAAC;QAClD,CAAC;QACD,KAAK,SAAS,CAAC,CAAC,CAAC;YACf,MAAM,EAAE,cAAc,EAAE,GAAG,MAAM,MAAM,CAAC,uBAAuB,CAAC,CAAC;YACjE,OAAO,cAAc,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC;QACnC,CAAC;QACD,KAAK,iBAAiB,CAAC,CAAC,CAAC;YACvB,MAAM,EAAE,qBAAqB,EAAE,GAAG,MAAM,MAAM,CAAC,+BAA+B,CAAC,CAAC;YAChF,OAAO,qBAAqB,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC;QAC1C,CAAC;QACD,KAAK,SAAS,CAAC,CAAC,CAAC;YACf,MAAM,EAAE,cAAc,EAAE,GAAG,MAAM,MAAM,CAAC,uBAAuB,CAAC,CAAC;YACjE,OAAO,cAAc,CAAC,IAAI,EAAE,GAAG,EAAE,SAAS,EAAE,GAAG,CAAC,CAAC;QACnD,CAAC;QACD;YACE,GAAG,CAAC,KAAK,CAAC,oBAAoB,GAAG,+CAA+C,CAAC,CAAC;YAClF,OAAO,CAAC,CAAC;IACb,CAAC;AACH,CAAC"}
|
|
@@ -73,6 +73,12 @@ export declare function missingBaseUrlRows(findings: readonly BaseUrlFinding[]):
|
|
|
73
73
|
* rename fired — there will eventually be more than one.
|
|
74
74
|
*/
|
|
75
75
|
export declare function removedPropRows(findings: readonly RemovedPropFinding[]): AdvisoryFindingRow[];
|
|
76
|
+
/** FR-043 §3.5 findings in the same row shape. */
|
|
77
|
+
export declare function libraryPrefixRows(findings: readonly {
|
|
78
|
+
file: string;
|
|
79
|
+
fqn: string;
|
|
80
|
+
message: string;
|
|
81
|
+
}[]): AdvisoryFindingRow[];
|
|
76
82
|
/**
|
|
77
83
|
* Print a capped run of advisory lines to stderr.
|
|
78
84
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"advisory.d.ts","sourceRoot":"","sources":["../../../src/lib/advisory.ts"],"names":[],"mappings":"AAuBA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAC7D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAC7D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAErE;;;;;;;;GAQG;AACH,eAAO,MAAM,sBAAsB,KAAK,CAAC;AAEzC,uEAAuE;AACvE,eAAO,MAAM,kBAAkB,QAAQ,CAAC;AAExC;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,CAUlE;AAMD,sEAAsE;AACtE,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,oEAAoE;IACpE,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,wEAAwE;AACxE,MAAM,WAAW,qBAAqB;IACpC,IAAI,EAAE,MAAM,CAAC;IACb;iFAC6E;IAC7E,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,mFAAmF;IACnF,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;;;GAIG;AACH,MAAM,WAAW,eAAe,CAAC,GAAG;IAClC,8EAA8E;IAC9E,MAAM,EAAE,KAAK,GAAG,SAAS,CAAC;IAC1B,uEAAuE;IACvE,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,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AAiB,CAC/B,QAAQ,EAAE,SAAS;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,EAAE,GAClE,kBAAkB,EAAE,CAQtB;AAMD;;;;;;;;;;GAUG;AACH,wBAAgB,UAAU,CACxB,KAAK,EAAE,SAAS,MAAM,EAAE,EACxB,KAAK,EAAE,MAAM,EACb,IAAI,EAAE;IAAE,UAAU,EAAE,OAAO,CAAA;CAAE,GAC5B,IAAI,CASN"}
|
package/dist/src/lib/advisory.js
CHANGED
|
@@ -97,6 +97,16 @@ export function removedPropRows(findings) {
|
|
|
97
97
|
message: f.message,
|
|
98
98
|
}));
|
|
99
99
|
}
|
|
100
|
+
/** FR-043 §3.5 findings in the same row shape. */
|
|
101
|
+
export function libraryPrefixRows(findings) {
|
|
102
|
+
return findings.map((f) => ({
|
|
103
|
+
file: f.file,
|
|
104
|
+
line: 0,
|
|
105
|
+
rule: "library-prefix-unprovenanced",
|
|
106
|
+
construct: f.fqn,
|
|
107
|
+
message: f.message,
|
|
108
|
+
}));
|
|
109
|
+
}
|
|
100
110
|
// ---------------------------------------------------------------------------
|
|
101
111
|
// text output
|
|
102
112
|
// ---------------------------------------------------------------------------
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"advisory.js","sourceRoot":"","sources":["../../../src/lib/advisory.ts"],"names":[],"mappings":"AAAA,gFAAgF;AAChF,2EAA2E;AAC3E,EAAE;AACF,+EAA+E;AAC/E,8EAA8E;AAC9E,iFAAiF;AACjF,+EAA+E;AAC/E,kFAAkF;AAClF,kFAAkF;AAClF,+DAA+D;AAC/D,EAAE;AACF,gEAAgE;AAChE,EAAE;AACF,mFAAmF;AACnF,+EAA+E;AAC/E,gBAAgB;AAChB,+EAA+E;AAC/E,+EAA+E;AAC/E,EAAE;AACF,gFAAgF;AAChF,sBAAsB;AAEtB,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC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,MAAM,UAAU,iBAAiB,CAC/B,QAAmE;IAEnE,OAAO,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;QAC1B,IAAI,EAAE,CAAC,CAAC,IAAI;QACZ,IAAI,EAAE,CAAC;QACP,IAAI,EAAE,8BAA8B;QACpC,SAAS,EAAE,CAAC,CAAC,GAAG;QAChB,OAAO,EAAE,CAAC,CAAC,OAAO;KACnB,CAAC,CAAC,CAAC;AACN,CAAC;AAED,8EAA8E;AAC9E,cAAc;AACd,8EAA8E;AAE9E;;;;;;;;;;GAUG;AACH,MAAM,UAAU,UAAU,CACxB,KAAwB,EACxB,KAAa,EACb,IAA6B;IAE7B,KAAK,MAAM,IAAI,IAAI,KAAK,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,CAAC;QAAE,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACzD,MAAM,QAAQ,GAAG,KAAK,CAAC,MAAM,GAAG,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;IAC9D,IAAI,QAAQ,IAAI,CAAC;QAAE,OAAO;IAC1B,GAAG,CAAC,IAAI,CACN,IAAI,CAAC,UAAU;QACb,CAAC,CAAC,UAAU,QAAQ,6DAA6D;QACjF,CAAC,CAAC,UAAU,QAAQ,qDAAqD,kBAAkB,GAAG,CACjG,CAAC;AACJ,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-context-staleness.d.ts","sourceRoot":"","sources":["../../../src/lib/agent-context-staleness.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"agent-context-staleness.d.ts","sourceRoot":"","sources":["../../../src/lib/agent-context-staleness.ts"],"names":[],"mappings":"AAYA;;;;GAIG;AACH,wBAAgB,uBAAuB,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAYzD"}
|
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
import { existsSync, readFileSync } from "node:fs";
|
|
2
2
|
import { join } from "node:path";
|
|
3
|
-
|
|
3
|
+
// The agent-context subpath, not the root barrel: `@metaobjectsdev/sdk` exports TWO
|
|
4
|
+
// types named `Manifest` — this one (the scaffolded agent context) via `export *`,
|
|
5
|
+
// and FR-023's `metaobjects.pkg.json` explicitly. An explicit export shadows a
|
|
6
|
+
// star one, so the root barrel now hands out the dependency manifest under this
|
|
7
|
+
// name. `init.ts` already imports these from the subpath; this was the last site
|
|
8
|
+
// reading them from the root.
|
|
9
|
+
import { AGENT_CONTEXT_MANIFEST_PATH, agentContextStaleness } from "@metaobjectsdev/sdk/agent-context";
|
|
4
10
|
import { cliVersion } from "./version.js";
|
|
5
11
|
import { log } from "./log.js";
|
|
6
12
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-context-staleness.js","sourceRoot":"","sources":["../../../src/lib/agent-context-staleness.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACnD,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,2BAA2B,EAAE,qBAAqB,EAAiB,MAAM,
|
|
1
|
+
{"version":3,"file":"agent-context-staleness.js","sourceRoot":"","sources":["../../../src/lib/agent-context-staleness.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACnD,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,oFAAoF;AACpF,mFAAmF;AACnF,+EAA+E;AAC/E,gFAAgF;AAChF,iFAAiF;AACjF,8BAA8B;AAC9B,OAAO,EAAE,2BAA2B,EAAE,qBAAqB,EAAiB,MAAM,mCAAmC,CAAC;AACtH,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAE/B;;;;GAIG;AACH,MAAM,UAAU,uBAAuB,CAAC,GAAW;IACjD,MAAM,CAAC,GAAG,IAAI,CAAC,GAAG,EAAE,2BAA2B,CAAC,CAAC;IACjD,IAAI,QAA8B,CAAC;IACnC,IAAI,UAAU,CAAC,CAAC,CAAC,EAAE,CAAC;QAClB,IAAI,CAAC;YACH,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,EAAE,MAAM,CAAC,CAAa,CAAC;QAC7D,CAAC;QAAC,MAAM,CAAC;YACP,OAAO,CAAC,mCAAmC;QAC7C,CAAC;IACH,CAAC;IACD,MAAM,GAAG,GAAG,qBAAqB,CAAC,EAAE,QAAQ,EAAE,cAAc,EAAE,UAAU,EAAE,EAAE,CAAC,CAAC;IAC9E,IAAI,GAAG,KAAK,IAAI;QAAE,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAClC,CAAC"}
|
package/dist/src/lib/args.d.ts
CHANGED
|
@@ -99,6 +99,12 @@ export interface GenFlags {
|
|
|
99
99
|
/** ADR-0021 D3 — print the stable-name generator registry and exit without
|
|
100
100
|
* running codegen. */
|
|
101
101
|
list: boolean;
|
|
102
|
+
/**
|
|
103
|
+
* `--list` only: construct every catalog generator and dry-run it against THIS
|
|
104
|
+
* project's model, reporting a real file count per generator. Needs a project;
|
|
105
|
+
* plain `--list` deliberately does not (it describes the installed engine).
|
|
106
|
+
*/
|
|
107
|
+
probe: boolean;
|
|
102
108
|
/** Suppress the advisory anti-pattern (verify-as-teacher) pass. */
|
|
103
109
|
noAntipatterns: boolean;
|
|
104
110
|
/**
|
|
@@ -121,6 +127,10 @@ export declare const GEN_OPTIONS: {
|
|
|
121
127
|
readonly type: "boolean";
|
|
122
128
|
readonly default: false;
|
|
123
129
|
};
|
|
130
|
+
readonly probe: {
|
|
131
|
+
readonly type: "boolean";
|
|
132
|
+
readonly default: false;
|
|
133
|
+
};
|
|
124
134
|
readonly "no-antipatterns": {
|
|
125
135
|
readonly type: "boolean";
|
|
126
136
|
readonly default: false;
|
|
@@ -201,7 +211,17 @@ export interface VerifyFlags {
|
|
|
201
211
|
* read as that flag's opposite rather than as a replay depth.
|
|
202
212
|
*/
|
|
203
213
|
replaySnapshot: boolean;
|
|
204
|
-
/**
|
|
214
|
+
/**
|
|
215
|
+
* Dependency drift (Task 15, FR-023) — re-resolve each declared dependency and
|
|
216
|
+
* compare its installed artifact's hash against `.metaobjects/deps.lock.json`
|
|
217
|
+
* (the same comparison `meta deps check` runs). Deliberately NEVER part of the
|
|
218
|
+
* bare-verify default, unlike --templates: it needs the publisher reachable,
|
|
219
|
+
* which CI may not have. It is still counted in `anyExplicit`, same as
|
|
220
|
+
* --codegen/--docs, so a lone `verify --deps` does not ALSO run the template
|
|
221
|
+
* gate.
|
|
222
|
+
*/
|
|
223
|
+
deps: boolean;
|
|
224
|
+
/** Whether ANY explicit subverb flag (--templates/--db/--codegen/--docs/--deps/--replay*) was passed. */
|
|
205
225
|
anyExplicit: boolean;
|
|
206
226
|
/** Suppress the advisory anti-pattern (verify-as-teacher) pass. */
|
|
207
227
|
noAntipatterns: boolean;
|
|
@@ -213,6 +233,16 @@ export interface VerifyFlags {
|
|
|
213
233
|
* the half that CAN fail a build switched on. Same shape as --no-antipatterns.
|
|
214
234
|
*/
|
|
215
235
|
noRequirementLint: boolean;
|
|
236
|
+
/**
|
|
237
|
+
* Suppress the advisory overlay AUTHORING lint (FR-023 §11.1 item 4) — the
|
|
238
|
+
* finding that an unflagged cross-file redeclaration works today only
|
|
239
|
+
* because the parser's default merge rule reuses the existing node by
|
|
240
|
+
* (type, resolutionKey); it silently becomes a NEW object the day the
|
|
241
|
+
* target is renamed or removed upstream. Same shape as
|
|
242
|
+
* --no-requirement-lint: mutes the advisory half only, never a gate (this
|
|
243
|
+
* lint has no gate half at all — it can never fail the build).
|
|
244
|
+
*/
|
|
245
|
+
noOverlayLint: boolean;
|
|
216
246
|
/**
|
|
217
247
|
* ADR-0023 strict-attr load opt-OUT (#96). `verify` is strict-by-default — an
|
|
218
248
|
* undeclared/typo'd own `@attr` fails verify (ERR_UNKNOWN_ATTR). `--lax`
|
|
@@ -267,6 +297,10 @@ export declare const VERIFY_OPTIONS: {
|
|
|
267
297
|
readonly type: "boolean";
|
|
268
298
|
readonly default: false;
|
|
269
299
|
};
|
|
300
|
+
readonly deps: {
|
|
301
|
+
readonly type: "boolean";
|
|
302
|
+
readonly default: false;
|
|
303
|
+
};
|
|
270
304
|
readonly replay: {
|
|
271
305
|
readonly type: "boolean";
|
|
272
306
|
readonly default: false;
|
|
@@ -283,6 +317,10 @@ export declare const VERIFY_OPTIONS: {
|
|
|
283
317
|
readonly type: "boolean";
|
|
284
318
|
readonly default: false;
|
|
285
319
|
};
|
|
320
|
+
readonly "no-overlay-lint": {
|
|
321
|
+
readonly type: "boolean";
|
|
322
|
+
readonly default: false;
|
|
323
|
+
};
|
|
286
324
|
readonly lax: {
|
|
287
325
|
readonly type: "boolean";
|
|
288
326
|
readonly default: false;
|
|
@@ -398,8 +436,14 @@ export declare const MIGRATE_OPTIONS: {
|
|
|
398
436
|
};
|
|
399
437
|
export declare function parseMigrateArgs(argv: string[]): MigrateFlags;
|
|
400
438
|
export interface EjectFlags {
|
|
401
|
-
/**
|
|
402
|
-
|
|
439
|
+
/**
|
|
440
|
+
* The generator names to eject, in the order given. Empty when only --list was given.
|
|
441
|
+
*
|
|
442
|
+
* MANY, not one: choosing a client tier means `form hooks grid`, and three separate
|
|
443
|
+
* invocations produce three separate install lines for the same package. The
|
|
444
|
+
* consolidated install set is the point of taking them together.
|
|
445
|
+
*/
|
|
446
|
+
names: string[];
|
|
403
447
|
list: boolean;
|
|
404
448
|
/** Overwrite an already-ejected file; default false — eject never clobbers. */
|
|
405
449
|
force: boolean;
|
|
@@ -416,5 +460,33 @@ export declare const EJECT_OPTIONS: {
|
|
|
416
460
|
};
|
|
417
461
|
};
|
|
418
462
|
export declare function parseEjectArgs(argv: string[]): EjectFlags;
|
|
463
|
+
/** `meta deps`'s subcommand. `sync` and `list` are this task's; `check` is
|
|
464
|
+
* parsed (so the grammar and its usage errors are stable now) but not yet
|
|
465
|
+
* implemented — Task 15 wires its behavior. */
|
|
466
|
+
export type DepsSubverb = "sync" | "check" | "list";
|
|
467
|
+
export interface DepsFlags {
|
|
468
|
+
subverb: DepsSubverb;
|
|
469
|
+
/** Dependency names to narrow to — `sync`'s `[<name>…]`. Empty means "all
|
|
470
|
+
* declared dependencies." Accepted (and ignored) by every subverb rather
|
|
471
|
+
* than rejected outright: the positional grammar is one shape for all
|
|
472
|
+
* three, and only `sync` gives the list meaning today. */
|
|
473
|
+
names: string[];
|
|
474
|
+
/** `sync` only: plan and report, write nothing. */
|
|
475
|
+
dryRun: boolean;
|
|
476
|
+
}
|
|
477
|
+
/** The flag table `parseDepsArgs` parses. Exported so the help text can be
|
|
478
|
+
* gated against it. Deliberately carries no "format" key: `--format` is a
|
|
479
|
+
* GLOBAL flag `index.ts` strips from argv before any command's parser ever
|
|
480
|
+
* runs (see `MIGRATE_OPTIONS`'s "--migration-format, not --format" note
|
|
481
|
+
* above) — `meta deps` becomes format-aware by index.ts adding "deps" to
|
|
482
|
+
* `FORMAT_AWARE_COMMANDS` and passing the resolved `fmt` through, exactly as
|
|
483
|
+
* gen/verify/migrate do, not by re-declaring the flag here. */
|
|
484
|
+
export declare const DEPS_OPTIONS: {
|
|
485
|
+
readonly "dry-run": {
|
|
486
|
+
readonly type: "boolean";
|
|
487
|
+
readonly default: false;
|
|
488
|
+
};
|
|
489
|
+
};
|
|
490
|
+
export declare function parseDepsArgs(argv: string[]): DepsFlags;
|
|
419
491
|
export {};
|
|
420
492
|
//# sourceMappingURL=args.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"args.d.ts","sourceRoot":"","sources":["../../../src/lib/args.ts"],"names":[],"mappings":"AAOA,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,OAAO,CAAC;IACf,KAAK,EAAE,OAAO,CAAC;IACf,SAAS,EAAE,OAAO,CAAC;I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,MAAM,YAAY;;;;;CAEf,CAAC;AAEX,wBAAgB,aAAa,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,SAAS,CAyBvD"}
|
package/dist/src/lib/args.js
CHANGED
|
@@ -63,6 +63,7 @@ export const GEN_OPTIONS = {
|
|
|
63
63
|
"dry-run": { type: "boolean", default: false },
|
|
64
64
|
"baseline": { type: "string" },
|
|
65
65
|
"list": { type: "boolean", default: false },
|
|
66
|
+
"probe": { type: "boolean", default: false },
|
|
66
67
|
"no-antipatterns": { type: "boolean", default: false },
|
|
67
68
|
"limit": { type: "string" },
|
|
68
69
|
};
|
|
@@ -85,6 +86,7 @@ export function parseGenArgs(argv) {
|
|
|
85
86
|
entities: positionals,
|
|
86
87
|
baseline: baselineRaw ?? "default",
|
|
87
88
|
list: !!values.list,
|
|
89
|
+
probe: !!values.probe,
|
|
88
90
|
noAntipatterns: !!values["no-antipatterns"],
|
|
89
91
|
// Throws on a bad value; the command layer reports it and exits 2, exactly as
|
|
90
92
|
// it does for --baseline above.
|
|
@@ -166,10 +168,12 @@ export const VERIFY_OPTIONS = {
|
|
|
166
168
|
templates: { type: "boolean", default: false },
|
|
167
169
|
codegen: { type: "boolean", default: false },
|
|
168
170
|
docs: { type: "boolean", default: false },
|
|
171
|
+
deps: { type: "boolean", default: false },
|
|
169
172
|
replay: { type: "boolean", default: false },
|
|
170
173
|
"replay-snapshot": { type: "boolean", default: false },
|
|
171
174
|
"no-antipatterns": { type: "boolean", default: false },
|
|
172
175
|
"no-requirement-lint": { type: "boolean", default: false },
|
|
176
|
+
"no-overlay-lint": { type: "boolean", default: false },
|
|
173
177
|
lax: { type: "boolean", default: false },
|
|
174
178
|
"d1": { type: "string" },
|
|
175
179
|
"remote": { type: "boolean", default: false },
|
|
@@ -214,14 +218,16 @@ export function parseVerifyArgs(argv) {
|
|
|
214
218
|
const templates = !!values.templates;
|
|
215
219
|
const codegen = !!values.codegen;
|
|
216
220
|
const docs = !!values.docs;
|
|
221
|
+
const deps = !!values.deps;
|
|
217
222
|
const replay = !!values.replay;
|
|
218
223
|
const replaySnapshot = !!values["replay-snapshot"];
|
|
219
224
|
// --db is itself an explicit subverb selector: passing a connection URL means
|
|
220
225
|
// "run the schema-drift mode". So is `--dialect d1` (D1 has no --db connection
|
|
221
226
|
// URL — see the `d1` field doc above). The replay flags are subverbs too, and
|
|
222
227
|
// must be listed here or `meta verify --replay` would ALSO run the template gate
|
|
223
|
-
// as the bare-verify default.
|
|
224
|
-
|
|
228
|
+
// as the bare-verify default. --deps joins the same list for the same reason —
|
|
229
|
+
// it must NOT also be part of that default (see the VerifyFlags doc on `deps`).
|
|
230
|
+
const anyExplicit = templates || codegen || docs || deps || values.db !== undefined || dialect === "d1" || replay || replaySnapshot;
|
|
225
231
|
return {
|
|
226
232
|
prompts: values.prompts,
|
|
227
233
|
db: values.db,
|
|
@@ -231,11 +237,13 @@ export function parseVerifyArgs(argv) {
|
|
|
231
237
|
templates,
|
|
232
238
|
codegen,
|
|
233
239
|
docs,
|
|
240
|
+
deps,
|
|
234
241
|
replay,
|
|
235
242
|
replaySnapshot,
|
|
236
243
|
anyExplicit,
|
|
237
244
|
noAntipatterns: !!values["no-antipatterns"],
|
|
238
245
|
noRequirementLint: !!values["no-requirement-lint"],
|
|
246
|
+
noOverlayLint: !!values["no-overlay-lint"],
|
|
239
247
|
lax: !!values.lax,
|
|
240
248
|
d1: values.d1,
|
|
241
249
|
remote: !!values.remote,
|
|
@@ -343,13 +351,54 @@ export function parseEjectArgs(argv) {
|
|
|
343
351
|
strict: true,
|
|
344
352
|
allowPositionals: true,
|
|
345
353
|
});
|
|
346
|
-
|
|
347
|
-
|
|
354
|
+
// `Set.add` returns the SET, which is always truthy — so the tempting
|
|
355
|
+
// `positionals.filter((n) => !seen.add(n))` never reports anything.
|
|
356
|
+
const seen = new Set();
|
|
357
|
+
const duplicates = [];
|
|
358
|
+
for (const n of positionals) {
|
|
359
|
+
if (seen.has(n))
|
|
360
|
+
duplicates.push(n);
|
|
361
|
+
else
|
|
362
|
+
seen.add(n);
|
|
363
|
+
}
|
|
364
|
+
if (duplicates.length > 0) {
|
|
365
|
+
throw new Error(`meta eject: repeated generator name(s): ${[...new Set(duplicates)].join(", ")}`);
|
|
348
366
|
}
|
|
349
367
|
return {
|
|
350
|
-
|
|
368
|
+
names: positionals,
|
|
351
369
|
list: !!values.list,
|
|
352
370
|
force: !!values.force,
|
|
353
371
|
};
|
|
354
372
|
}
|
|
373
|
+
const DEPS_SUBVERBS = ["sync", "check", "list"];
|
|
374
|
+
/** The flag table `parseDepsArgs` parses. Exported so the help text can be
|
|
375
|
+
* gated against it. Deliberately carries no "format" key: `--format` is a
|
|
376
|
+
* GLOBAL flag `index.ts` strips from argv before any command's parser ever
|
|
377
|
+
* runs (see `MIGRATE_OPTIONS`'s "--migration-format, not --format" note
|
|
378
|
+
* above) — `meta deps` becomes format-aware by index.ts adding "deps" to
|
|
379
|
+
* `FORMAT_AWARE_COMMANDS` and passing the resolved `fmt` through, exactly as
|
|
380
|
+
* gen/verify/migrate do, not by re-declaring the flag here. */
|
|
381
|
+
export const DEPS_OPTIONS = {
|
|
382
|
+
"dry-run": { type: "boolean", default: false },
|
|
383
|
+
};
|
|
384
|
+
export function parseDepsArgs(argv) {
|
|
385
|
+
const { values, positionals } = parseArgs({
|
|
386
|
+
args: argv,
|
|
387
|
+
options: DEPS_OPTIONS,
|
|
388
|
+
strict: true,
|
|
389
|
+
allowPositionals: true,
|
|
390
|
+
});
|
|
391
|
+
const [subverbRaw, ...names] = positionals;
|
|
392
|
+
if (subverbRaw === undefined) {
|
|
393
|
+
throw new Error("meta deps requires a subcommand: sync | check | list. Try `meta deps sync`.");
|
|
394
|
+
}
|
|
395
|
+
if (!DEPS_SUBVERBS.includes(subverbRaw)) {
|
|
396
|
+
throw new Error(`meta deps: unknown subcommand "${subverbRaw}"; expected one of: ${DEPS_SUBVERBS.join(", ")}.`);
|
|
397
|
+
}
|
|
398
|
+
return {
|
|
399
|
+
subverb: subverbRaw,
|
|
400
|
+
names,
|
|
401
|
+
dryRun: !!values["dry-run"],
|
|
402
|
+
};
|
|
403
|
+
}
|
|
355
404
|
//# sourceMappingURL=args.js.map
|