From 336ea8b691f148b81db62e24bb55c7ca11ddbc6c Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Sun, 20 Aug 2023 13:08:07 +0300 Subject: [PATCH] CI: Only attempt publish for upstream (#1179) Only attempt publish for upstream Co-authored-by: Hynek Schlawack --- .github/workflows/pypi-package.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pypi-package.yml b/.github/workflows/pypi-package.yml index cdd26b99..0c056c1a 100644 --- a/.github/workflows/pypi-package.yml +++ b/.github/workflows/pypi-package.yml @@ -33,7 +33,7 @@ jobs: release-test-pypi: name: Publish in-dev package to test.pypi.org environment: release-test-pypi - if: github.event_name == 'push' && github.ref == 'refs/heads/main' + if: github.repository_owner == 'python-attrs' && github.event_name == 'push' && github.ref == 'refs/heads/main' runs-on: ubuntu-latest needs: build-package @@ -53,7 +53,7 @@ jobs: release-pypi: name: Publish released package to pypi.org environment: release-pypi - if: github.event.action == 'published' + if: github.repository_owner == 'python-attrs' && github.event.action == 'published' runs-on: ubuntu-latest needs: build-package