From 180060525d054f04f6a477f8a571da24edb1c2ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=98topepo=E2=80=99?= Date: Mon, 16 Dec 2024 15:26:11 -0500 Subject: [PATCH] add a GHA to preview PRs --- .github/.gitignore | 1 + .github/workflows/preview.yml | 30 ++++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) create mode 100644 .github/.gitignore create mode 100644 .github/workflows/preview.yml diff --git a/.github/.gitignore b/.github/.gitignore new file mode 100644 index 0000000..2d19fc7 --- /dev/null +++ b/.github/.gitignore @@ -0,0 +1 @@ +*.html diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml new file mode 100644 index 0000000..c191f9b --- /dev/null +++ b/.github/workflows/preview.yml @@ -0,0 +1,30 @@ +name: Quarto Preview + +on: + pull_request: + types: + - opened + - reopened + - synchronize + - closed + +jobs: + build-deploy: + runs-on: ubuntu-latest + permissions: + contents: write + pull-requests: write + steps: + - name: Check out repository + uses: actions/checkout@v4 + + - name: Setup Quarto + uses: quarto-dev/quarto-actions/setup@v2 + + - name: Render + uses: quarto-dev/quarto-actions/render@v2 + + - name: Deploy PR Preview + uses: rossjrw/pr-preview-action@v1.4.8 + with: + source-dir: ./_book/