From 9080a7c8d779e71ec991d8d096f24c6dcade1d58 Mon Sep 17 00:00:00 2001 From: Ben McCann <322311+benmccann@users.noreply.github.com> Date: Fri, 8 Nov 2024 13:41:57 -0800 Subject: [PATCH 1/2] chore: setup pkg.pr.new --- .github/workflows/ci.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 486af3633207..c754c5f185f8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,6 +19,17 @@ permissions: contents: read # to fetch code (actions/checkout) jobs: + pkg-pr-new: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: pnpm/action-setup@v4.0.0 + - uses: actions/setup-node@v4 + with: + node-version: 22 + cache: pnpm + - run: pnpm install --frozen-lockfile + - run: pnpx pkg-pr-new publish --comment=off ./packages/kit lint-all: runs-on: ubuntu-latest steps: @@ -26,7 +37,7 @@ jobs: - uses: pnpm/action-setup@v4.0.0 - uses: actions/setup-node@v4 with: - node-version: '18.x' + node-version: 22 cache: pnpm - run: pnpm install --frozen-lockfile - run: pnpm run lint From 5a12204f9a0c04ce45f010e97d4f3f0df3722751 Mon Sep 17 00:00:00 2001 From: Ben McCann <322311+benmccann@users.noreply.github.com> Date: Fri, 8 Nov 2024 13:53:01 -0800 Subject: [PATCH 2/2] docs: update contributing guide --- CONTRIBUTING.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index ca6709e3b704..df548cfa14bc 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -22,7 +22,7 @@ pnpm install You can use the playground at [`playgrounds/basic`](./playgrounds/basic/) to experiment with your changes to SvelteKit locally. -### Linking +### Linking local changes If you want to test against an existing project, you can use [pnpm `overrides`](https://pnpm.io/package_json#pnpmoverrides) in that project: @@ -39,6 +39,14 @@ If you want to test against an existing project, you can use [pnpm `overrides`]( } ``` +### Testing PR changes + +Each pull request will be built and published via [pkg.pr.new/](https://pkg.pr.new/). You can test the change by installing the package with your PR number: + +``` +npm add https://pkg.pr.new/sveltejs/kit/@sveltejs/kit@YOUR_PR_NUMBER_GOES_HERE +``` + ## Code structure Entry points to be aware of are: