changed ci #6
Workflow file for this run
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: Build and Deploy Packages | ||
|
Check failure on line 1 in .github/workflows/build-and-deploy.yml
|
||
| on: | ||
| push: | ||
| tags: | ||
| - 'v[0-9]*' | ||
| - feature/ci_test | ||
| workflow_dispatch: | ||
| jobs: | ||
| wheels: | ||
| runs-on: ${{ matrix.os }} | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| include: | ||
| - os: ubuntu-20.04 | ||
| - os: macos-11 | ||
| - os: windows-2019 | ||
| architecture: x86 | ||
| - os: windows-2019 | ||
| architecture: AMD64 | ||
| steps: | ||
| - uses: actions/checkout@v3 | ||
| - uses: docker/setup-qemu-action@v2 | ||
| with: | ||
| platforms: arm64 | ||
| if: runner.os == 'Linux' | ||
| - uses: bus1/cabuild/action/msdevshell@v1 | ||
| with: | ||
| architecture: x64 | ||
| if: runner.os == 'Windows' && matrix.architecture == 'AMD64' | ||
| - uses: bus1/cabuild/action/msdevshell@v1 | ||
| with: | ||
| architecture: x86 | ||
| if: runner.os == 'Windows' && matrix.architecture == 'x86' | ||
| - run: pip3 install pipx | ||
| - run: pipx run cibuildwheel==2.11.2 | ||
| env: | ||
| CIBW_SKIP: pp* cp36-* *-musllinux* | ||
| CIBW_ARCHS_MACOS: x86_64 arm64 | ||
| CIBW_ARCHS_LINUX: x86_64 aarch64 | ||
| CIBW_ARCHS_WINDOWS: ${{ matrix.architecture }} | ||
| - uses: actions/upload-artifact@v3 | ||
| with: | ||
| path: wheelhouse/*.whl | ||
| sdist: | ||
| needs: | ||
| - release | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v3 | ||
| - run: python -m pip install build meson | ||
| - run: python -m build --sdist | ||
| - uses: actions/upload-artifact@v3 | ||
| with: | ||
| path: dist/*.tar.gz | ||
| deploy-to-pypi: | ||
| name: Deploy to PyPI (Manual) | ||
| runs-on: ubuntu-latest | ||
| needs: [wheels, sdist] | ||
| if: github.event_name == 'workflow_dispatch' | ||
| environment: pypi-deployment | ||
| steps: | ||
| - name: Download all artifacts | ||
| uses: actions/download-artifact@v4 | ||
| with: | ||
| path: ./dist/ | ||
| - name: Flatten artifact structure | ||
| run: | | ||
| mkdir -p ./upload/ | ||
| find ./dist/ -name "*.whl" -exec cp {} ./upload/ \; | ||
| find ./dist/ -name "*.tar.gz" -exec cp {} ./upload/ \; | ||
| ls -la ./upload/ | ||
| - name: Publish to PyPI | ||
| uses: pypa/gh-action-pypi-publish@release/v1 | ||
| with: | ||
| repository-url: ${{ vars.REPO_URL }} | ||
| username: ${{ vars.USER }} | ||
| password: ${{ secrets.PASSWORD }} | ||
| packages-dir: ./upload/ | ||
| verbose: true | ||