Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .github/workflows/mirror-private-scope.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ name: Mirror released bytes into the private scope
# exactly the released tarball, verified against the integrity every lock pins, and nothing else.
# Written while this repository's owner was offline, under the operator's service-matrix alignment
# instruction (platform Chief decision 08858c6a); the owner may keep, change or remove it.
# A package's first publication from this public repository is public on GitHub Packages whatever
# --access says: make it private before granting consumers Read. Later versions keep its settings.

on:
workflow_dispatch:
Expand Down Expand Up @@ -127,7 +129,10 @@ jobs:
const { EXPECTED_SHA512, MIRROR_SHA256, RUNNER_TEMP, PACKAGE, VERSION } = process.env;
const fail = message => { console.error(message); process.exit(1); };
const directory = `${RUNNER_TEMP}/mirror/readback`;
const dist = JSON.parse(readFileSync(`${directory}/packument-dist.json`, 'utf8'));
// npm 12.2 prints `view <spec> dist --json` as a one-element array.
const viewed = JSON.parse(readFileSync(`${directory}/packument-dist.json`, 'utf8'));
if (Array.isArray(viewed) && viewed.length !== 1) fail('Expected one packument dist entry');
const dist = Array.isArray(viewed) ? viewed[0] : viewed;
const files = readdirSync(directory).filter(name => name.endsWith('.tgz'));
if (files.length !== 1) fail('Expected exactly one tarball read back');
const bytes = readFileSync(`${directory}/${files[0]}`);
Expand Down
2 changes: 1 addition & 1 deletion RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ One root `vX.Y.Z` tag versions the Go module and TypeScript package together. bi
- Go module: `github.com/Bitspark/bitruntime`, packages `core/go`, `websocket/go` and `hydrated/go`.
- TypeScript package: `@bitspark/bitruntime`, subpaths `/core`, `/websocket` and `/hydrated`.
- TypeScript distribution: GitHub release asset `bitspark-bitruntime-<version>.tgz`, covered by `SHA256SUMS`. This is an npm-compatible tarball, not a registry publication. URL installs with npm 12 require `--allow-remote=root`.
- Private-scope mirror: the released asset is also mirrored, byte for byte, into the private `@bitspark` scope on GitHub Packages, for Bitspark's private consumers whose `@bitspark` scope resolves there (`.github/workflows/mirror-private-scope.yml`). The public distribution above is unchanged.
- Private-scope mirror: the released asset is also mirrored, byte for byte, into the private `@bitspark` scope on GitHub Packages, for Bitspark's private consumers whose `@bitspark` scope resolves there (`.github/workflows/mirror-private-scope.yml`). The public distribution above is unchanged. The mirror package is private: its first publication from this public repository was public on GitHub Packages despite `--access=restricted`, and was set private before any consumer was granted Read. Later versions keep the package's settings.

Before tagging, land a reviewed green PR on main. CI requires Go formatting/vet/race tests, TypeScript checking/build/tests, bitwire conformance observations, a fresh installed package consumer, and Go/TypeScript WebSocket and hydrated interoperability. Run the same checks locally where supported. Confirm bitwire's exact dependency release is publicly installable, with no file dependencies, module replacements or private registries. Run `node scripts/go-smoke.mjs <pushed-commit>` before tagging.

Expand Down
Loading