@vzn/vx 0.0.602 → 0.0.603

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.602",
3
+ "version": "0.0.603",
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.602",
25
- "@vzn/vx-linux-arm64": "0.0.602",
26
- "@vzn/vx-darwin-x64": "0.0.602",
27
- "@vzn/vx-darwin-arm64": "0.0.602"
24
+ "@vzn/vx-linux-x64": "0.0.603",
25
+ "@vzn/vx-linux-arm64": "0.0.603",
26
+ "@vzn/vx-darwin-x64": "0.0.603",
27
+ "@vzn/vx-darwin-arm64": "0.0.603"
28
28
  },
29
29
  "dependencies": {
30
30
  "@anthropic-ai/sandbox-runtime": "^0.0.76"
@@ -272,6 +272,7 @@ export function makeRootEventFilter(
272
272
  (isWorkspaceFingerprintFile(rel) ||
273
273
  isWorkspaceConfigFile(rel) ||
274
274
  rel === 'package.json' ||
275
+ rel === '.gitignore' ||
275
276
  claimedRootFiles.has(rel))
276
277
  ) {
277
278
  return true
package/src/cli/watch.ts CHANGED
@@ -164,7 +164,15 @@ export async function watchCmd(args: readonly string[]): Promise<number> {
164
164
  const workspaceRoot = await findWorkspaceRoot(cwd, reads)
165
165
  const workspace = await loadWorkspace(workspaceRoot, reads)
166
166
  const allProjects = await discoverCliProjects(workspace)
167
- const anchored = opts.tasks.filter((t) => t.includes('#')).map((t) => t.slice(0, t.indexOf('#')))
167
+ // `//#check` is the root project's task, named by its package.json name
168
+ // as the run names it (prepare.ts, D-39): taken literally, no project
169
+ // was in scope and the watch exited 1 after a green run.
170
+ const rootDir = path.resolve(workspaceRoot)
171
+ const rootName = allProjects.find((p) => path.resolve(p.dir) === rootDir)?.name
172
+ const anchored = opts.tasks
173
+ .filter((t) => t.includes('#'))
174
+ .map((t) => t.slice(0, t.indexOf('#')))
175
+ .map((p) => (p === '//' && rootName !== undefined ? rootName : p))
168
176
  const named =
169
177
  anchored.length === opts.tasks.length
170
178
  ? new Set(anchored)
@@ -586,6 +594,7 @@ async function runWatchLoop(args: WatchLoopArgs): Promise<void> {
586
594
  isWorkspaceFingerprintFile(filename) ||
587
595
  isWorkspaceConfigFile(filename) ||
588
596
  filename === 'package.json' ||
597
+ filename === '.gitignore' ||
589
598
  claimedRootFiles.has(filename)
590
599
  ) {
591
600
  if (shapesWatchedSet(filename) || filename === LOCKFILE_NAME) reread = true
@@ -845,6 +854,15 @@ async function runWatchLoop(args: WatchLoopArgs): Promise<void> {
845
854
  base,
846
855
  arm(base, false, (filename) => {
847
856
  if (isIgnoredWatchPath(filename)) return
857
+ // Inputs are gitignore-aware: an edit here changes what the
858
+ // members' keys read, and `vx run` would miss on it.
859
+ if (filename === '.gitignore') {
860
+ trigger(
861
+ path.relative(workspaceRoot, path.join(base, filename)),
862
+ path.join(base, filename),
863
+ )
864
+ return
865
+ }
848
866
  // Only a member coming or going. On macOS a non-recursive watcher
849
867
  // also reports a member whose CONTENTS changed (FSEvents names the
850
868
  // directory a write landed in), so a task writing into its own