Commit Graph

7 Commits

Author SHA1 Message Date
Matt Isenhower
941a6eb258 Remove unused catch binding variables in fs.mjs
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 10:09:17 -08:00
Matt Isenhower
6dac044a69 Make VFS load lazily
VFS now loads on first has()/getMtime() call rather than requiring
explicit initialization in sync/index.mjs. This ensures it works
regardless of entry point (sync:download, splatnet:quick, etc.).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 09:55:13 -08:00
Matt Isenhower
e6e96ac8f9 Check local disk before VFS, removing need for manual vfs.track()
exists() and olderThan() now check the local filesystem first and only
consult the VFS as a fallback. This means freshly written files are
found naturally without callers needing to register them.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 09:27:00 -08:00
Matt Isenhower
41c9f9a315 Add VFS layer to avoid downloading files only needed for existence checks
Uses S3 ListObjectsV2 to build an in-memory file listing at startup,
allowing exists() and olderThan() to resolve from the listing instead
of requiring files on disk. sync:download now skips assets/splatnet/,
data/xrank/, data/festivals.ranking.*, and status-screenshots/.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 09:26:05 -08:00
Matt Isenhower
7adb9c313e Add mkdirp utility to avoid verbose fs.mkdir calls
Added mkdirp() helper to app/common/fs.mjs that wraps
fs.mkdir(dir, { recursive: true }). Updated all call sites to use it.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 11:09:02 -08:00
Matt Isenhower
46fdbbe8c7 Clean up the way we detect whether an update is needed 2023-04-22 14:05:59 -07:00
Matt Isenhower
cda854de0b Add a utility function to check whether a file exists 2023-04-22 13:33:04 -07:00