diff options
Diffstat (limited to '.github/workflows/examples-deploy.yml')
-rw-r--r-- | .github/workflows/examples-deploy.yml | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/.github/workflows/examples-deploy.yml b/.github/workflows/examples-deploy.yml new file mode 100644 index 000000000..06cecbe1e --- /dev/null +++ b/.github/workflows/examples-deploy.yml @@ -0,0 +1,22 @@ +# This workflow runs when changes to examples are pushed to main. +# It calls a build hook on Netlify that will redeploy preview.astro.new with the latest changes. + +name: Redeploy preview.astro.new + +on: + push: + branches: + - main + paths: + - 'examples/**' + workflow_dispatch: + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 + - name: Send a POST request to Netlify to rebuild preview.astro.new + run: 'curl -X POST -d {} ${{ env.BUILD_HOOK }}' + env: + BUILD_HOOK: ${{ secrets.NETLIFY_PREVIEWS_BUILD_HOOK }} |