Refactor publish step in GitHub Actions workflow

This commit is contained in:
BillTheMaker
2025-12-06 19:32:08 -07:00
committed by GitHub
parent f9ecbae6a4
commit 15da5eb1c2

View File

@@ -48,31 +48,31 @@ jobs:
name: wheels-${{ matrix.os }}-${{ matrix.target }} name: wheels-${{ matrix.os }}-${{ matrix.target }}
path: dist path: dist
publish: publish:
name: Publish to PyPI name: Publish to PyPI
needs: [build_wheels] needs: [build_wheels]
runs-on: ubuntu-latest runs-on: ubuntu-latest
# REMOVED problematic if condition # REMOVED problematic if condition
steps: steps:
- name: Install maturin for upload - name: Install maturin for upload
run: pip install maturin run: pip install maturin
- name: Download ALL wheels - name: Download ALL wheels
uses: actions/download-artifact@v4 uses: actions/download-artifact@v4
with: with:
path: dist path: dist
- name: Flatten wheels to dist/ - name: Flatten wheels to dist/
run: | run: |
find dist -name "*.whl" -exec cp {} dist/ \; find dist -name "*.whl" -exec cp {} dist/ \;
echo "Wheels ready:" echo "Wheels ready:"
ls -la dist/*.whl ls -la dist/*.whl
- name: Publish to PyPI - name: Publish to PyPI
env: env:
PYPI_TOKEN: ${{ secrets.PYPI_API_TOKEN }} PYPI_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
run: | run: |
cd dist cd dist
ls -la *.whl ls -la *.whl
maturin upload --skip-existing --non-interactive maturin upload --skip-existing --non-interactive