|
| 1 | +# Preview packages (pkg.pr.new) |
| 2 | + |
| 3 | +Nothing is published to npm yet. Every CI package-preview run publishes real, |
| 4 | +installable tarballs of both workspace packages to [pkg.pr.new](https://pkg.pr.new) |
| 5 | +— a free continuous-release registry keyed by commit SHA and pull request. |
| 6 | +These are the packages to install until a first npm release is cut. |
| 7 | + |
| 8 | +## Install the latest preview |
| 9 | + |
| 10 | +Reference a pull request number to track its most recent build: |
| 11 | + |
| 12 | +```sh |
| 13 | +npm i https://pkg.pr.new/ScriptedAlchemy/agent-bundle/agent-bundle@1 |
| 14 | +npm i https://pkg.pr.new/ScriptedAlchemy/agent-bundle/@agent-bundle/rsc-runtime@1 |
| 15 | +``` |
| 16 | + |
| 17 | +`@1` resolves to the last preview published for PR #1 — commit `5685521` at the |
| 18 | +time of its merge, which is the state that landed on `main`. |
| 19 | + |
| 20 | +## Pin an exact commit |
| 21 | + |
| 22 | +Any commit that had a package-preview run can be installed by SHA (short SHAs |
| 23 | +work), which is the right form for lockfiles and reproducible setups: |
| 24 | + |
| 25 | +```sh |
| 26 | +npm i https://pkg.pr.new/ScriptedAlchemy/agent-bundle/agent-bundle@5685521 |
| 27 | +npm i https://pkg.pr.new/ScriptedAlchemy/agent-bundle/@agent-bundle/rsc-runtime@5685521 |
| 28 | +``` |
| 29 | + |
| 30 | +pnpm and yarn accept the same URLs (`pnpm add <url>`, `yarn add agent-bundle@<url>`). |
| 31 | + |
| 32 | +## Where previews come from |
| 33 | + |
| 34 | +`.github/workflows/package-preview.yml` runs |
| 35 | +`pnpm preview:publish` (`pkg-pr-new publish './packages/agent-bundle' |
| 36 | +'./packages/rsc-runtime'`) after a full build, on every pull request and on |
| 37 | +every push to `main`. The "Publish pkg.pr.new preview" check on a PR or commit |
| 38 | +links to the exact URLs for that build. Previews are built from the same |
| 39 | +`pnpm build` output the release gates verify; they are not npm releases and |
| 40 | +carry preview version strings. |
0 commit comments