We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0daad33 commit cfda2acCopy full SHA for cfda2ac
.github/workflows/pr-preview.yml
@@ -0,0 +1,34 @@
1
+name: PR Preview
2
+
3
+on:
4
+ pull_request:
5
+ branches: [ main ]
6
7
+jobs:
8
+ build-and-deploy:
9
+ runs-on: ubuntu-latest
10
11
+ steps:
12
+ - name: Checkout
13
+ uses: actions/checkout@v4
14
+ with:
15
+ fetch-depth: 0
16
17
+ - name: Setup Node
18
+ uses: actions/setup-node@v4
19
20
+ node-version: 18
21
22
+ - name: Install dependencies
23
+ run: npm ci
24
25
+ - name: Build site
26
+ run: npm run build
27
28
+ - name: Deploy PR preview
29
+ uses: peaceiris/actions-gh-pages@v3
30
31
+ github_token: ${{ secrets.GITHUB_TOKEN }}
32
+ publish_branch: gh-pages
33
+ publish_dir: ./build
34
+ destination_dir: previews/pr-${{ github.event.pull_request.number }}
0 commit comments