mirror of
https://github.com/vercel-labs/scriptc.git
synced 2026-11-09 11:14:22 +08:00
spm runs pnpm, enumerates installed package instances from the isolated node_modules/.pnpm layout, locates each instance's upstream TypeScript (local override, tarball source or sourcesContent, npm provenance, registry gitHead, version tag), fetches the package directory at that commit (blobless sparse git, or the codeload archive with an in-process gzip + tar reader), verifies it against the published artifact (byte-exact sourcesContent, token-normalized re-emit equivalence, a structural check for bundles, and an exported-name surface check), and writes per-instance overlays plus .scriptc-pm/manifest.json (schema 1) and scriptc-sources.lock.json for scriptc --sources. It has no npm dependencies and compiles to a native binary with scriptc; scripts/smoke.sh checks that the Node and native lanes produce identical output on the public demo app in examples/spm-demo. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>