-
Notifications
You must be signed in to change notification settings - Fork 47
37 lines (35 loc) · 1006 Bytes
/
preview.yaml
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
name: Doc Preview
on:
pull_request:
branches: [main]
jobs:
preview:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
lfs: true
- run: git lfs pull
- uses: pnpm/[email protected]
with:
version: latest
run_install: false
- run: |
npm install
- run: |
npm run build
- name: Deploy to Netlify
uses: nwtgck/[email protected]
id: netlify
with:
publish-dir: './build'
enable-pull-request-comment: true
enable-commit-comment: true
overwrites-pull-request-comment: true
deploy-message: "Preview Deploy for ${{ github.event.pull_request.title }}"
github-token: ${{ secrets.PUBLIC_REPO }}
fails-without-credentials: true
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
timeout-minutes: 2