From cadbbd17c4df6c081e39123c33ee44165b397945 Mon Sep 17 00:00:00 2001 From: Ben Mares Date: Sat, 14 Sep 2024 13:47:06 +0200 Subject: [PATCH] Only run the publish job on releases This is causing the status of `main` to hang yellow because the publish job now runs in a protected environment that requires manual authorization. --- .github/workflows/release.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 3282a50d1..c8834f96d 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -43,6 +43,7 @@ jobs: publish: runs-on: ubuntu-latest + if: ${{ github.event_name == 'release' }} needs: build # Run this job in an isolated GHA environment containing the OIDC credentials. environment: release @@ -54,5 +55,4 @@ jobs: name: dist-files path: dist - name: Publish a Python distribution to PyPI - if: ${{ github.event_name == 'release' }} uses: pypa/gh-action-pypi-publish@v1.10.1