From a63c4ea9e1cecc73c074150b836c041c9bf1f08e Mon Sep 17 00:00:00 2001 From: "George G. Vega Yon" Date: Thu, 24 Oct 2024 08:24:15 -0600 Subject: [PATCH] Adding the post-page-artifact job (#456) * Adding the post-page-artifact job * Updating to use the cfa-action/post-artifact * Removing unnecesary data for the action * More cleaning --- .github/workflows/website.yaml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/website.yaml b/.github/workflows/website.yaml index 22807b8b..794a8181 100644 --- a/.github/workflows/website.yaml +++ b/.github/workflows/website.yaml @@ -53,6 +53,7 @@ jobs: uses: actions/upload-pages-artifact@v3 with: name: github-pages + retention-days: 7 path: docs/build/html/ deploy: @@ -75,3 +76,20 @@ jobs: with: artifact_name: github-pages preview: true + + post-page-artifact: + if: ${{ github.event_name == 'pull_request' }} + needs: build + runs-on: ubuntu-latest + permissions: + contents: read + pull-requests: write + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Post comment preview + uses: CDCgov/cfa-actions/post-artifact@v1.0.0 + with: + artifact-name: github-pages + gh-token: ${{ secrets.GITHUB_TOKEN}}