diff --git a/.github/workflows/cleanup-pr-preview.yml b/.github/workflows/cleanup-pr-preview.yml index 952116301..ee2261294 100644 --- a/.github/workflows/cleanup-pr-preview.yml +++ b/.github/workflows/cleanup-pr-preview.yml @@ -5,6 +5,8 @@ on: jobs: cleanup: runs-on: ubuntu-latest + # PRs from forks don't create previews + if: github.event_name == 'pull_request' && !github.event.pull_request.head.repo.fork permissions: contents: write steps: diff --git a/.github/workflows/update.yml b/.github/workflows/update.yml index 06a526547..f0bf3e5a3 100644 --- a/.github/workflows/update.yml +++ b/.github/workflows/update.yml @@ -66,7 +66,8 @@ jobs: git-config-name: github-actions[bot] git-config-email: 41898282+github-actions[bot]@users.noreply.github.com - name: Deploy metadata view to subdirectory if pull request 🚀 - if: github.event_name == 'pull_request' + # This does not work for PRs from forks + if: github.event_name == 'pull_request' && !github.event.pull_request.head.repo.fork uses: JamesIves/github-pages-deploy-action@v4 with: folder: build @@ -75,6 +76,7 @@ jobs: git-config-name: github-actions[bot] git-config-email: 41898282+github-actions[bot]@users.noreply.github.com - uses: actions/upload-artifact@v5 + if: always() with: name: build path: build