-
Notifications
You must be signed in to change notification settings - Fork 3
40 lines (35 loc) · 1.08 KB
/
netlify.yml
File metadata and controls
40 lines (35 loc) · 1.08 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
name: Netlify
on:
pull_request:
push:
branches:
- master
jobs:
Deploy:
runs-on: ubuntu-latest
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
- uses: nelonoel/branch-name@v1.0.1
- name: Publish preview
uses: jsmrcaga/action-netlify-deploy@v2.4.0
if: env.NETLIFY_AUTH_TOKEN
with:
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
NETLIFY_AUTH_TOKEN: ${{ env.NETLIFY_AUTH_TOKEN }}
NETLIFY_DEPLOY_MESSAGE: Preview ${{ env.BRANCH_NAME }}
build_directory: packages/demo/dist
monorepo_package: shape-to-query
deploy_alias: ${{ env.BRANCH_NAME }}
NETLIFY_DEPLOY_TO_PROD: ${{ env.BRANCH_NAME == 'master' }}
- uses: exercism/pr-commenter-action@v1.4.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
template-variables: |
{
"url": "${{ env.NETLIFY_PREVIEW_URL }}"
}