From 69a424bd0881d6b3f8c181a75527f1e9db1f1bfa Mon Sep 17 00:00:00 2001 From: tree Date: Fri, 24 Feb 2023 08:57:55 +0100 Subject: [PATCH] Update github actions --- .github/workflows/gh-pages.yml | 30 ++++++++++++++++++++---------- 1 file changed, 20 insertions(+), 10 deletions(-) diff --git a/.github/workflows/gh-pages.yml b/.github/workflows/gh-pages.yml index 6331e79d..e0d015e4 100644 --- a/.github/workflows/gh-pages.yml +++ b/.github/workflows/gh-pages.yml @@ -7,8 +7,8 @@ on: workflow_dispatch: jobs: - build_and_deploy: - runs-on: ubuntu-22.04 + build: + runs-on: ubuntu-latest permissions: contents: write concurrency: @@ -34,12 +34,22 @@ jobs: - name: Add custom domain run: 'touch build/CNAME && echo "explore.prgblockweek.com" >> build/CNAME' - - name: Deploy - uses: peaceiris/actions-gh-pages@v3 - # If you're changing the branch from main, - # also change the `main` in `refs/heads/main` - # below accordingly. - if: ${{ github.ref == 'refs/heads/main' }} + - uses: actions/configure-pages@v3 + - uses: actions/upload-pages-artifact@v1 with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: ./build + path: 'build' + + deploy: + needs: [build] + runs-on: ubuntu-latest + permissions: + contents: read + pages: write + id-token: write + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + steps: + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v1