Skip to content

Commit 3ce799d

Browse files
committed
ci: pkg pr new workflow
1 parent a84422e commit 3ce799d

1 file changed

Lines changed: 44 additions & 0 deletions

File tree

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: pkg.pr.new Preview
2+
3+
on:
4+
pull_request:
5+
types:
6+
- opened
7+
- synchronize
8+
- reopened
9+
- ready_for_review
10+
push:
11+
branches:
12+
- main
13+
- master
14+
15+
permissions:
16+
contents: read
17+
pull-requests: write
18+
19+
jobs:
20+
publish-preview:
21+
runs-on: ubuntu-latest
22+
steps:
23+
- name: Checkout
24+
uses: actions/checkout@v4
25+
26+
- name: Setup pnpm
27+
uses: pnpm/action-setup@v4
28+
with:
29+
run_install: false
30+
31+
- name: Setup Node
32+
uses: actions/setup-node@v4
33+
with:
34+
node-version: 20
35+
cache: pnpm
36+
37+
- name: Install dependencies
38+
run: pnpm install --frozen-lockfile
39+
40+
- name: Build package
41+
run: pnpm build
42+
43+
- name: Publish preview with pkg.pr.new
44+
run: pnpm dlx pkg-pr-new publish --packageManager=pnpm --bin docs-cache

0 commit comments

Comments
 (0)