Nightly Wheel builder #22
This file contains 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: Nightly Wheel builder | |
on: | |
workflow_dispatch: | |
schedule: | |
- cron: "27 11 * * SUN" # every Sunday at 11:27 UTC | |
push: | |
branches: | |
- maintenance/** | |
concurrency: | |
# Cancel previous workflows on the same branch | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
permissions: | |
contents: read | |
jobs: | |
call-workflow-build-wheels: | |
uses: ./.github/workflows/wheels_recipe.yml | |
with: | |
CIBW_ENVIRONMENT: > | |
PIP_PRE=1 | |
PIP_EXTRA_INDEX_URL="https://pypi.anaconda.org/scientific-python-nightly-wheels/simple" | |
# assert NumPy 2.0 before running tests | |
CIBW_TEST_COMMAND: > | |
pip list --pre --format=freeze | grep -q 'numpy==2' && | |
pytest --pyargs skimage | |
upload_anaconda: | |
permissions: | |
contents: write # for softprops/action-gh-release to create GitHub release | |
name: Release | |
needs: call-workflow-build-wheels | |
if: github.repository_owner == 'scikit-image' && github.ref == 'refs/heads/main' | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/download-artifact@v3 | |
id: download | |
with: | |
name: wheels | |
path: ./dist | |
- name: Upload wheel | |
uses: scientific-python/upload-nightly-action@b67d7fcc0396e1128a474d1ab2b48aa94680f9fc # 0.5.0 | |
with: | |
artifacts_path: dist | |
anaconda_nightly_upload_token: ${{secrets.UPLOAD_TOKEN}} |