File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2020 check :
2121 name : Check build
2222 runs-on : ubuntu-latest
23+ env :
24+ NETLIFY_AUTH_TOKEN : ${{ secrets.NETLIFY_AUTH_TOKEN }}
25+ NETLIFY_SITE_ID : ${{ secrets.NETLIFY_SITE_ID }}
2326
2427 steps :
2528 - name : Checkout
4649 run : npm ci
4750 - name : Build demo
4851 working-directory : ./demo
49- run : npm run build
52+ run : npm run build:netlify
53+ - name : Deploy demo preview to Netlify
54+ if : github.event.pull_request.head.repo.full_name == github.repository && env.NETLIFY_AUTH_TOKEN != '' && env.NETLIFY_SITE_ID != ''
55+ uses : nwtgck/actions-netlify@v3.0
56+ with :
57+ publish-dir : ' ./demo/dist'
58+ production-branch : ${{ github.event.repository.default_branch }}
59+ production-deploy : false
60+ alias : deploy-preview-${{ github.event.pull_request.number }}
61+ github-token : ${{ secrets.GITHUB_TOKEN }}
62+ deploy-message : PR # ${{ github.event.pull_request.number }} - ${{ github.event.pull_request.title }}
63+ enable-pull-request-comment : true
64+ overwrites-pull-request-comment : true
65+ netlify-config-path : ./demo/netlify.toml
66+ timeout-minutes : 1
You can’t perform that action at this time.
0 commit comments