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