@vzn/vx 0.0.441 → 0.0.443

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": "@vzn/vx",
3
- "version": "0.0.441",
3
+ "version": "0.0.443",
4
4
  "description": "The fastest task runner and build cache for JavaScript monorepos.",
5
5
  "type": "module",
6
6
  "exports": {
@@ -21,10 +21,10 @@
21
21
  "node": ">=18"
22
22
  },
23
23
  "optionalDependencies": {
24
- "@vzn/vx-linux-x64": "0.0.441",
25
- "@vzn/vx-linux-arm64": "0.0.441",
26
- "@vzn/vx-darwin-x64": "0.0.441",
27
- "@vzn/vx-darwin-arm64": "0.0.441"
24
+ "@vzn/vx-linux-x64": "0.0.443",
25
+ "@vzn/vx-linux-arm64": "0.0.443",
26
+ "@vzn/vx-darwin-x64": "0.0.443",
27
+ "@vzn/vx-darwin-arm64": "0.0.443"
28
28
  },
29
29
  "dependencies": {
30
30
  "@anthropic-ai/sandbox-runtime": "^0.0.76"
package/src/cli/init.ts CHANGED
@@ -98,6 +98,7 @@ export async function initCmd(args: readonly string[]): Promise<number> {
98
98
  if (await Bun.file(path.join(root, 'nx.json')).exists()) {
99
99
  return adopt(root, 'nx', 'nx.json', parsed)
100
100
  }
101
+ const unmapped = namelessNotes(root, nameless)
101
102
  return applyMigration({
102
103
  root,
103
104
  metas,
@@ -108,10 +109,8 @@ export async function initCmd(args: readonly string[]): Promise<number> {
108
109
  ),
109
110
  source: 'package.json scripts',
110
111
  verb: 'vx init',
111
- notes: [
112
- ...(await unreadWorkspaces(root, workspace.packageGlobs)),
113
- ...namelessNotes(root, nameless),
114
- ],
112
+ notes: [...(await unreadWorkspaces(root, workspace.packageGlobs)), ...unmapped],
113
+ unmapped: unmapped.length > 0,
115
114
  dry: parsed.dry,
116
115
  force: parsed.force,
117
116
  init: true,
@@ -9,8 +9,8 @@
9
9
  // folded in — instead of each re-deriving an ad-hoc shape from the raw,
10
10
  // rendering-oriented `WireEvent` stream.
11
11
  //
12
- // A sink is observe-only BY CONSTRUCTION: its only input is an immutable
13
- // record; its `TelemetryContext` carries read-only metadata and NO mutable
12
+ // A sink is observe-only BY CONSTRUCTION: its only input is a plain-data
13
+ // record (one object every sink receives, not frozen); its `TelemetryContext` carries read-only metadata and NO mutable
14
14
  // run handle (no bus, no Cache, no RunRequest). There is no API path from a
15
15
  // sink back into scheduling/caching/exec — telemetry provably cannot change
16
16
  // what or how tasks run. Contrast `cache`/`executor`, which return objects
@@ -234,6 +234,12 @@ export interface ApplyMigrationArgs {
234
234
  init?: boolean
235
235
  /** Report lines printed under the source line (e.g. "turbo.json found and not read"). */
236
236
  notes?: readonly string[]
237
+ /**
238
+ * Scripts exist but no project can carry them (a member without a
239
+ * `name`): the empty report said "no package.json scripts" of a repo full
240
+ * of them (M-59).
241
+ */
242
+ unmapped?: boolean
237
243
  /**
238
244
  * `ts` (default) writes `vx.config.ts` with the type-only import and
239
245
  * `satisfies`; `mjs` writes `vx.config.mjs` — the same object, untyped —
@@ -388,7 +394,9 @@ export async function applyMigration(args: ApplyMigrationArgs): Promise<number>
388
394
  )
389
395
  } else if (empty) {
390
396
  report.push(
391
- `${verb}: no package.json scripts to turn into tasks.`,
397
+ args.unmapped === true
398
+ ? `${verb}: no package.json scripts became tasks.`
399
+ : `${verb}: no package.json scripts to turn into tasks.`,
392
400
  ...[...noMembers, ...(args.notes ?? [])].map((n) => `note: ${n}`),
393
401
  hasWorkspaceFile
394
402
  ? `${workspaceName} already exists.`