Merge pull request #202 from supermihi/chore/v3.2.0 #269
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: main | |
| on: [push, pull_request] | |
| jobs: | |
| sdist: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - name: Set up Python | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.x" | |
| - name: install pip dependencies | |
| run: | | |
| python -m pip install --upgrade pip build | |
| - name: sdist | |
| run: python -m build --sdist | |
| - name: upload sdist | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: sdist | |
| path: dist | |
| retention-days: 5 | |
| build_wheels: | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, macos-14, macos-15, windows-latest] | |
| runs-on: ${{ matrix.os }} | |
| env: | |
| CIBW_ARCHS: auto64 | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - name: cache native build artifacts | |
| uses: actions/cache@v5 | |
| with: | |
| path: build | |
| key: taglib-${{ matrix.os }}-${{ hashFiles('build_native_taglib.py') }} | |
| - name: build binary wheels | |
| uses: pypa/cibuildwheel@v3.3.0 | |
| - name: upload wheels | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: bdist-${{ matrix.os }} | |
| path: ./wheelhouse/*.whl | |
| retention-days: 5 | |
| publish: | |
| runs-on: ubuntu-latest | |
| needs: [build_wheels, sdist] | |
| if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | |
| steps: | |
| - name: download source wheel | |
| uses: actions/download-artifact@v7 | |
| with: | |
| name: sdist | |
| path: wheels | |
| - name: download binary wheels | |
| uses: actions/download-artifact@v7 | |
| with: | |
| pattern: bdist-* | |
| path: wheels | |
| merge-multiple: true | |
| - name: publish package pypi.org | |
| uses: pypa/gh-action-pypi-publish@release/v1 | |
| with: | |
| user: __token__ | |
| password: ${{ secrets.PYPI_API_TOKEN }} | |
| skip-existing: true | |
| packages-dir: wheels |