INT-04 (#181). This documents what is publish-ready, the order, and the one open design question. Nothing here publishes anything: the workflow is manual-only and the owner dispatches it after review.
The JS runtime packages are JSR-publishable today. deno publish
--dry-run succeeds for both (verified during INT-04 prep):
| Package | Spec | Notes |
|---|---|---|
|
|
Loader + marshal |
|
|
TEA runtime.
Depends on |
Publish order is load-bearing: affine-js must publish before
affinescript-tea (the latter resolves @hyperpolymath/affine-js/loader).
affinescript-dom is AffineScript source (.affine), not a JS package
— it is consumed by the compiler, not JSR; out of scope for JSR.
The JS entrypoints emit JSR’s unsupported-javascript-entrypoint
(slow-types) warning — expected for a JS-with-JSDoc package; it
publishes, only @hyperpolymath/affine-js’s fast-check is skipped.
`types.d.ts already provides the consumer-facing contract. Converting
entrypoints is out of scope for INT-04 (tracked separately if desired).
-
Review
deno publish --dry-run(CI:Publish to JSR (manual)withdry_run: true, or locallycd <pkg> && deno publish --dry-run). -
Dispatch
.github/workflows/publish-jsr.ymlforaffine-jswithdry_run: false(JSR OIDC viaid-token: write— no token secret). -
Then dispatch it for
affinescript-tea.
"then npm" (#181) is a separate, later step and is not wired by
this prep. If/when needed it follows the existing owner-sanctioned npm
pattern (.github/workflows/affine-vscode-publish.yml, NPM_TOKEN
scoped automation token) — a deliberate exception to Deno-first.
#181 says "publish compiler + runtime". The runtime is the JS packages above. The compiler is a native OCaml binary — not a JSR/npm package. The one-way-door fork (#260) was decided (ADR-019): Releases-canonical, dual-channel.
-
Canonical artifact.
.github/workflows/release.yml(#260 S2), on av*tag, buildsaffinescript-{linux-x64,macos-x64,macos-arm64}raw binaries + aSHA256SUMSmanifest attached to the GitHub Release. (windows-x64is a tracked follow-up.) Asset names are the ADR-019 contract — do not rename without amending the ADR + the shim. -
Ergonomic front door.
packages/affinescript-cli(@hyperpolymath/affinescript, #260 S3) — a thin Deno shim that downloads the host-triple binary from the Release pinned inpins.js, verifies it against the embedded SHA-256 (fail-closed: an unpinned/mismatched binary is never executed), caches it under$AFFINESCRIPT_CACHE/XDG, and execs it with the caller’s argv. One compiler version + checksum per shim release (no floating fetch). Publish is owner-gated viapublish-jsr.yml(the INT-04 manual workflow; choiceaffinescript-cli). -
Later, additive over the same Release artifact (not separate producers): Guix/Nix fetch-derivations; an npm tail only if an npm-native consumer needs it.
affinescript-lsp distribution (INT-10, #282) consumes the shim;
unblocked once a v* Release is cut and pins.js is finalised.