-
-
Notifications
You must be signed in to change notification settings - Fork 241
42 lines (33 loc) · 1.14 KB
/
release-continuous.yml
File metadata and controls
42 lines (33 loc) · 1.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: Preview Publish
on:
push:
branches:
- main
pull_request:
types: [opened, synchronize, labeled]
permissions: {}
jobs:
preview:
if: >
github.repository == 'vitejs/vite-plugin-react' &&
(github.event_name == 'push' ||
(github.event_name == 'pull_request' && contains(github.event.pull_request.labels.*.name, 'trigger: preview')))
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6
- name: Install pnpm
uses: pnpm/action-setup@08c4be7e2e672a47d11bd04269e27e5f3e8529cb # v6.0.0
- uses: actions/setup-node@v6
with:
node-version: lts/*
# disable cache, to avoid cache poisoning (https://docs.zizmor.sh/audits/#cache-poisoning)
package-manager-cache: false
- name: Disallow installation scripts
run: yq '.onlyBuiltDependencies = []' -i pnpm-workspace.yaml
- name: Install dependencies
run: pnpm install
- name: Build
run: pnpm build
- name: Publish
run: pnpm dlx pkg-pr-new@0.0 publish --pnpm --compact './packages/*' './packages/plugin-react-swc/dist'