pi-mono/scripts
Christian Klotz db774055e3
Set up preview packages (#11260)
* feat: publish preview packages to pkg.earendil.com

CI packs every public package after the build, with internal dependencies
pointing at the same commit's builds. A workflow_run job publishes them to
the earendil-pkg worker with the job's GitHub OIDC token, moves main or
pr-<n>, and comments install commands on the PR. Closing a PR deletes its
ref. pi-env is left out because its daemons are only built for releases.

* feat: publish preview packages only for main and same-repo PRs

pkg.earendil.com requires a consumer token, so fork authors could not
install their previews anyway. Fork PRs are no longer packed or
published, which keeps fork code out of the registry and removes the PR
lookup: the PR number now comes from the workflow_run event. The PR
comment is dropped; the job summary lists the install commands.

* fix: pick the PR into main and describe only the workflow in preview-packages.yml

- Read the PR number from the workflow_run pull request list with jq,
  selecting the PR into main; a branch can also have PRs into other
  branches, and the index expression tripped workflow linters.
- Comments describe what the workflow does and what it needs from
  pkg.earendil.com, not how the service works.

* fix: gate preview publishing to main pushes and open PRs into main

- Publish only CI runs for pushes to main and for pull requests. A branch
  can make its own copy of CI run on push; those runs are unreviewed and
  were uploaded as push builds.
- Move pr-<number> only while the PR is open into main with this commit
  as its head, checked live, so a late publish cannot recreate the ref of
  a closed PR; otherwise publish without a ref and print a notice.
- Set concurrency per job, so skipped fork runs never wait in a group.

* docs: drop the service rule from the preview-packages.yml header

* docs: name the earendil-works/pkg worker in the preview script
2026-10-22 11:43:08 +02:00
..
biome feat(ai,coding-agent): unify image and classifier model infrastructure (#9948) 2026-09-23 17:41:19 +02:00
issues feat: checkpointWhen is required on Durable document definitions 2026-10-19 18:17:42 +00:00
agent-treeshake-smoke-entry.ts fix(agent): restore streamFn extension compatibility 2026-07-21 18:37:07 +02:00
auto-pi.sh fix(coding-agent): support bundled experimental processes 2026-08-24 14:17:17 +02:00
biome-check.mjs build: share root config with pi-private 2026-10-11 16:36:26 +00:00
browser-smoke-entry.ts feat(chord): replace the facet and service runtime with the chord2 host runtime 2026-10-12 10:41:59 +00:00
build-binaries.sh fix(coding-agent): disable .env autoload in standalone binary 2026-10-06 09:57:14 +02:00
build-coding-agent-bundle.mjs feat(coding-agent): remove the experimental server stack and the client, protocol, and server packages 2026-10-12 10:41:59 +00:00
check-browser-smoke.mjs feat: add durable JSONL storage backend 2026-09-23 01:33:31 +02:00
check-entry-graphs.mjs Revert "feat(durable): replicate storages as a commit log" 2026-10-21 14:39:26 +02:00
check-lockfile-commit.mjs feat(coding-agent): remove npm shrinkwrap and recommend the managed installer 2026-10-02 17:16:56 +02:00
check-model-catalog-compat.mjs feat: check the model catalog against the latest release before publishing (#11007) 2026-10-15 21:21:57 +02:00
check-package-install.mjs feat: unify package artifact validation (#10197) 2026-10-06 13:30:02 +02:00
check-pinned-deps.mjs fix: pin internal dependencies to exact versions 2026-10-13 14:28:15 +02:00
check-pinned-deps.test.mjs fix: pin internal dependencies to exact versions 2026-10-13 14:28:15 +02:00
check-runtime-deps.mjs feat(codemode): run sandboxes on Cloudflare Workers via a remote Durable Object 2026-10-10 14:41:36 +02:00
check-runtime-deps.test.mjs fix(coding-agent): keep remote harness dependencies development-only 2026-09-05 12:45:04 +02:00
check-ts-relative-imports.mjs feat: build with TypeScript 7 and run sources with plain node 2026-09-25 13:14:33 +02:00
coding-agent-smoke.mjs feat(coding-agent): remove the experimental server stack and the client, protocol, and server packages 2026-10-12 10:41:59 +00:00
coding-agent-smoke.test.mjs feat(coding-agent): remove the experimental server stack and the client, protocol, and server packages 2026-10-12 10:41:59 +00:00
cost.ts chore: pin dependencies and use native TypeScript 2026-05-20 12:46:17 +02:00
create-source-archive.sh feat(ai,coding-agent): unify image and classifier model infrastructure (#9948) 2026-09-23 17:41:19 +02:00
diff-model-catalog.mjs generate-models: use reasoning options from models.dev (#6928) 2026-07-22 08:33:34 +02:00
durable-browser-smoke-entry.ts feat: add durable JSONL storage backend 2026-09-23 01:33:31 +02:00
edit-tool-stats.mjs fix(coding-agent): built-in tools work like extension tools 2026-03-22 04:20:38 +01:00
generate-coding-agent-install-lock.mjs feat(coding-agent): remove the experimental server stack and the client, protocol, and server packages 2026-10-12 10:41:59 +00:00
generate-thinking-capabilities.mjs generate-models: use reasoning options from models.dev (#6928) 2026-07-22 08:33:34 +02:00
local-package-install.mjs feat: unify package artifact validation (#10197) 2026-10-06 13:30:02 +02:00
local-package-install.test.mjs feat: unify package artifact validation (#10197) 2026-10-06 13:30:02 +02:00
local-release.mjs feat: unify package artifact validation (#10197) 2026-10-06 13:30:02 +02:00
model-catalog-minimum-version.mjs feat: check the model catalog against the latest release before publishing (#11007) 2026-10-15 21:21:57 +02:00
model-catalog-protocol.test.ts feat: share model catalog protocol with pi.dev (#9763) 2026-09-23 20:08:05 +02:00
model-catalog-protocol.ts feat: share model catalog protocol with pi.dev (#9763) 2026-09-23 20:08:05 +02:00
npm-audit.mjs chore: accept unfixable node-forge advisory in npm audit 2026-10-02 18:49:34 +02:00
npm-command.mjs feat: unify package artifact validation (#10197) 2026-10-06 13:30:02 +02:00
pack-packages.mjs feat: unify package artifact validation (#10197) 2026-10-06 13:30:02 +02:00
package-artifact-cli.test.mjs feat: unify package artifact validation (#10197) 2026-10-06 13:30:02 +02:00
package-artifacts.mjs fix: support npm 12 pack JSON output (#10680) 2026-10-08 17:26:34 +02:00
package-artifacts.test.mjs fix: support npm 12 pack JSON output (#10680) 2026-10-08 17:26:34 +02:00
package-workspaces.mjs feat(agent): prepare SQLite storage package for publishing 2026-07-21 14:13:14 +02:00
preview-packages.mjs Set up preview packages (#11260) 2026-10-22 11:43:08 +02:00
preview-packages.test.mjs Set up preview packages (#11260) 2026-10-22 11:43:08 +02:00
profile-coding-agent-node.mjs feat(coding-agent): remove the experimental server stack and the client, protocol, and server packages 2026-10-12 10:41:59 +00:00
publish-model-catalog.mjs feat: check the model catalog against the latest release before publishing (#11007) 2026-10-15 21:21:57 +02:00
publish-model-catalog.test.mjs feat(ai,coding-agent): unify image and classifier model infrastructure (#9948) 2026-09-23 17:41:19 +02:00
publish-release-announcement.mjs feat(coding-agent): update managed installations in place 2026-08-24 09:34:34 +02:00
publish-release-announcement.test.mjs fix(coding-agent): announce only verified npm releases 2026-08-06 22:39:09 +02:00
publish.mjs feat: unify package artifact validation (#10197) 2026-10-06 13:30:02 +02:00
read-tool-stats.mjs feat(scripts): add session context stats 2026-05-07 22:18:19 +02:00
release-notes.mjs fix(coding-agent): fix changelog links 2026-06-08 20:31:20 +02:00
release-packages.mjs feat: unify package artifact validation (#10197) 2026-10-06 13:30:02 +02:00
release.mjs fix: keep the Nix model catalog pin buildable 2026-10-15 20:16:03 +02:00
repro-5893-wsl-bash.mjs fix(coding-agent): run legacy WSL bash commands via stdin 2026-06-19 15:08:25 +02:00
session-context-stats.mjs feat(scripts): add session context stats 2026-05-07 22:18:19 +02:00
session-transcripts.ts chore: pin dependencies and use native TypeScript 2026-05-20 12:46:17 +02:00
smoke-test-codemode-binary.mjs fix(coding-agent): load codemode worker in Windows binary 2026-09-30 13:48:04 +02:00
stats.ts chore: pin dependencies and use native TypeScript 2026-05-20 12:46:17 +02:00
sync-versions.js feat(ai,agent,coding-agent): move client identity and provider attribution into pi-ai 2026-10-21 11:17:02 +00:00
sync-versions.test.mjs feat(ai,agent,coding-agent): move client identity and provider attribution into pi-ai 2026-10-21 11:17:02 +00:00
tool-stats.ts fix(oauth): harden browser launch handling 2026-06-02 23:15:46 +02:00
update-model-catalog-pin.mjs fix: keep the Nix model catalog pin buildable 2026-10-15 20:16:03 +02:00
update-model-catalog-pin.test.mjs fix: keep the Nix model catalog pin buildable 2026-10-15 20:16:03 +02:00
update-source-imports-to-ts.sh chore(ts): use source import extensions 2026-05-20 00:04:03 +02:00
use-local-packages.mjs feat: unify package artifact validation (#10197) 2026-10-06 13:30:02 +02:00