0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2024-12-30 22:03:56 -05:00
astro/.github/workflows/examples-deploy.yml
Chris Swithinbank 04aede3255
Examples fixes and preview.astro.new support (#12543)
Co-authored-by: Emanuele Stoppa <602478+ematipico@users.noreply.github.com>
2024-11-27 16:08:37 +01:00

22 lines
590 B
YAML

# 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@v4
- 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 }}