Skip to content

Commit

Permalink
Change upload logic to merge artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
Opt-Mucca committed Oct 30, 2024
1 parent e56d0b6 commit 573de28
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions .github/workflows/build_wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ jobs:

- uses: actions/upload-artifact@v4
with:
name: wheels-${{ matrix.os}}-${{ matrix.arch }}
path: ./wheelhouse/*.whl

build_sdist:
Expand All @@ -64,16 +65,24 @@ jobs:

- uses: actions/upload-artifact@v4
with:
name: source-distribution
path: dist/*.tar.gz

upload_pypi:
merge:
needs: [build_wheels, build_sdist]
runs-on: ubuntu-latest
steps:
- name: Merge Artifacts
uses: actions/upload-artifact/merge@v4

upload_pypi:
needs: [build_wheels, build_sdist, merge]
runs-on: ubuntu-latest
if: github.event.inputs.upload_to_pypi == 'true'
steps:
- uses: actions/download-artifact@v4
with:
name: artifact
name: merged-artifacts
path: dist

- uses: pypa/gh-action-pypi-publish@release/v1
Expand Down

0 comments on commit 573de28

Please sign in to comment.