Build wheel #1
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 wheel | |
| on: [workflow_dispatch, workflow_call] | |
| concurrency: | |
| group: ${{ github.head_ref || github.run_id }} | |
| cancel-in-progress: true | |
| jobs: | |
| build: | |
| strategy: | |
| fail-fast: true | |
| matrix: | |
| platform: [windows-latest] | |
| env: | |
| CIBW_SKIP: 'pp*' | |
| CIBW_ARCHS: 'auto64' | |
| CIBW_PROJECT_REQUIRES_PYTHON: '==3.12' | |
| CIBW_TEST_REQUIRES: 'pytest' | |
| defaults: | |
| run: | |
| shell: bash -l {0} | |
| runs-on: ${{ matrix.platform }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| submodules: true | |
| - name: Set up Python version ${{ matrix.version }} | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: "3.x" | |
| - name: Build Wheel | |
| run: | | |
| # Hack to ensure installed RAT package is used for test instead | |
| # of local package. | |
| mkdir tmp | |
| cp -r tests tmp/tests/ | |
| export PATH="$pythonLocation:$PATH" | |
| CIBW_TEST_COMMAND='cd ${pwd}/tmp && python -m pytest tests' | |
| echo "CIBW_TEST_COMMAND=${CIBW_TEST_COMMAND}" >> $GITHUB_ENV | |
| python -m pip install cibuildwheel==2.16.5 | |
| python -m cibuildwheel --output-dir ./wheelhouse | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: wheels-${{ runner.os }}-${{ strategy.job-index }} | |
| path: ./wheelhouse/*.whl |