From 95ad16c3419d861aa5d2f78afdccffa989d366d5 Mon Sep 17 00:00:00 2001 From: Chris Harris Date: Tue, 4 Jun 2024 14:09:45 +0000 Subject: [PATCH 1/2] Rename release workflow --- .github/workflows/{release-py-rpm.yml => release.yml} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/workflows/{release-py-rpm.yml => release.yml} (100%) diff --git a/.github/workflows/release-py-rpm.yml b/.github/workflows/release.yml similarity index 100% rename from .github/workflows/release-py-rpm.yml rename to .github/workflows/release.yml From 99f4f99ff8f0a4ef9156e4e49575c260e6be2866 Mon Sep 17 00:00:00 2001 From: Chris Harris Date: Tue, 4 Jun 2024 14:41:09 +0000 Subject: [PATCH 2/2] Add step to publish to PyPI --- .github/workflows/release.yml | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 323b220..8b2f768 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,9 +1,10 @@ -name: Release Python Based RPM +name: Release Python Based RPM and Publish to PyPI run-name: ${{ github.triggering_actor }} is packaging a release of ${{ github.event.repository.name }} on: - push: - tags: - - 'v*' # push events matching e.g. v1, v2.1, v10.0.3 + workflow_dispatch: # Allow manual triggering of the workflow + push: + tags: + - 'v*' # push events matching e.g. v1, v2.1, v10.0.3 permissions: contents: read @@ -14,6 +15,7 @@ jobs: runs-on: ubuntu-latest permissions: contents: write + id-token: write steps: - name: Checkout code @@ -23,6 +25,9 @@ jobs: id: build_podman_hpc uses: ./.github/actions/build-podman-hpc + - name: Publish package to PyPI + uses: pypa/gh-action-pypi-publish@81e9d935c883d0b210363ab89cf05f3894778450 #v1.8.14 + - name: Release id: release uses: softprops/action-gh-release@de2c0eb89ae2a093876385947365aca7b0e5f844 #v1