Skip to content

Commit

Permalink
ci: Publish GitHub attestations only for PyPI builds (#157)
Browse files Browse the repository at this point in the history
* TestPyPI distributions are not important enough to have duplicate
  human readable attestations.
  • Loading branch information
matthewfeickert authored Jun 17, 2024
1 parent 903b435 commit 2c28fa3
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions .github/workflows/publish-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,8 @@ jobs:
run: python -m zipfile --list dist/recast_atlas-*.whl

- name: Generate artifact attestation for sdist and wheel
# If publishing to TestPyPI or PyPI
if: >-
(github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') && github.repository == 'recast-hep/recast-atlas')
|| (github.event_name == 'workflow_dispatch' && github.event.inputs.publish == 'true' && github.repository == 'recast-hep/recast-atlas')
|| (github.event_name == 'release' && github.event.action == 'published' && github.repository == 'recast-hep/recast-atlas')
# If publishing to PyPI
if: github.event_name == 'release' && github.event.action == 'published' && github.repository == 'recast-hep/recast-atlas'
uses: actions/attest-build-provenance@534b352d658f90498fd148d231fdbf88f3886a3a # v1.3.1
with:
subject-path: "dist/recast_atlas-*"
Expand Down

0 comments on commit 2c28fa3

Please sign in to comment.