Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,11 @@ jobs:
url: https://pypi.org/p/nullrun
permissions:
id-token: write
# contents: write is required by softprops/action-gh-release to
# create the GitHub Release (push the tag ref + draft release).
# The existing publish step only needs id-token for PyPI Trusted
# Publishing, so this is additive and scoped to the new step.
contents: write

steps:
- uses: actions/checkout@v4
Expand All @@ -63,3 +68,22 @@ jobs:

- name: Publish to PyPI (Trusted Publishing)
uses: pypa/gh-action-pypi-publish@release/v1

# GitHub Release creation — gated on tag pushes so the manual
# workflow_dispatch path (used for hotfix re-runs) doesn't create
# a duplicate release on the current HEAD's branch ref. The
# ``generate_release_notes`` flag asks GitHub to auto-aggregate
# merged PR titles + labels into the release body, which keeps
# the GitHub release page in sync with the CHANGELOG.md body
# without manual editing. Attached files mirror what PyPI receives
# (wheel + sdist) so the release page doubles as a download mirror
# for environments where pip isn't available.
- name: Create GitHub Release
if: startsWith(github.ref, 'refs/tags/v')
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.ref_name }}
generate_release_notes: true
files: |
dist/*.whl
dist/*.tar.gz
Loading