diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 15bdb229..3bfe136c 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -10,7 +10,37 @@ permissions: pull-requests: read jobs: - build: + build-windows-and-mac: + strategy: + matrix: + os: [windows-latest, macos-latest] + python: ['3.9', '3.10', '3.11', '3.12'] + runs-on: ${{ matrix.os }} + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup python + uses: actions/setup-python@v4 + with: + python-version: ${{ matrix.python }} + + - name: Build lib + run: | + pip install wheel + python setup.py develop + python setup.py bdist_wheel + + - name: List contents of dist + run: ls -R dist + + - name: Archive build artifacts + uses: actions/upload-artifact@v4 + with: + name: dist-artifacts + path: dist + + build-linux: runs-on: ubuntu-latest container: image: quay.io/pypa/manylinux2014_x86_64 @@ -56,12 +86,12 @@ jobs: - name: Archive build artifacts uses: actions/upload-artifact@v3 with: - name: build-artifacts-none-any + name: wheelhouse-artifacts path: wheelhouse deploy: runs-on: ubuntu-latest - needs: build + needs: [build-linux, build-windows-and-mac] steps: - name: Checkout uses: actions/checkout@v4 @@ -79,22 +109,20 @@ jobs: - name: Download build artifacts for windows and mac wheels uses: actions/download-artifact@v4 with: - path: dist + path: dist-artifacts merge-multiple: true - name: Download build artifacts for manylinux wheels uses: actions/download-artifact@v4 with: - path: wheelhouse + path: wheelhouse-artifacts merge-multiple: true - name: Inspect dist files - run: | - ls -R dist + run: ls -R dist - name: Inspect wheelhouse files - run: | - ls -R wheelhouse + run: ls -R wheelhouse - name: Merge wheel files run: | @@ -102,8 +130,7 @@ jobs: ls -R wheelhouse - name: Upload to PyPI using twine - run: | - twine upload --skip-existing wheelhouse/* + run: twine upload --skip-existing wheelhouse/* env: TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }} TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}