diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c5ad05e..5329d20 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -8,15 +8,13 @@ on: tags: - '*' -jobs: - cleanup-runs: - runs-on: ubuntu-latest - steps: - - uses: rokroskar/workflow-run-cleanup-action@master - env: - GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" - if: "!startsWith(github.ref, 'refs/tags/') && github.ref != 'refs/heads/master'" +# https://docs.github.com/en/actions/using-jobs/using-concurrency#example-using-a-fallback-value +# Only cancels-in-progress on PRs (head_ref only defined in PR, fallback run_id always unique) +concurrency: + group: ${{ github.head_ref || github.run_id }} + cancel-in-progress: true +jobs: build: runs-on: ${{ matrix.os }} defaults: @@ -25,17 +23,17 @@ jobs: strategy: fail-fast: false matrix: - os: [ ubuntu-20.04, macos-11, windows-2019 ] - python-version: [ 3.7, 3.9, 3.8, "3.10", "3.11", "3.12" ] + os: [ ubuntu-20.04, macos-12, windows-2019 ] + python-version: [ 3.9, 3.8, "3.10", "3.11", "3.12" ] env: PYTHON_VERSION: ${{ matrix.python-version }} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: submodules: recursive - - uses: conda-incubator/setup-miniconda@v2 + - uses: conda-incubator/setup-miniconda@v3 with: auto-update-conda: true python-version: ${{ matrix.python-version }} @@ -70,13 +68,13 @@ jobs: strategy: fail-fast: false matrix: - os: [ ubuntu-20.04, macos-11, windows-2019 ] + os: [ ubuntu-20.04, macos-12, windows-2019 ] python-version: [ 3.7, 3.9, "3.10", "3.11", "3.12" ] include: - os: ubuntu-20.04 python-version: 3.8 single_action_config: "True" - - os: macos-11 + - os: macos-12 python-version: 3.8 - os: windows-2019 python-version: 3.8 @@ -91,10 +89,10 @@ jobs: steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: submodules: recursive - - uses: actions/setup-python@v2 + - uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} - name: Set Additional Envs @@ -109,7 +107,7 @@ jobs: env: CIBW_BUILD: "cp3${{env.PYTHON_SUBVERSION}}-*" CIBW_SKIP: "*-win32 *-manylinux_i686 *-musllinux*" - uses: joerick/cibuildwheel@v2.16.5 + uses: pypa/cibuildwheel@v2.19.1 - name: Build source if: ${{env.DEPLOY == 'True' && env.SINGLE_ACTION_CONFIG == 'True'}} @@ -126,7 +124,7 @@ jobs: - name: Upload artifacts to github if: ${{env.DEPLOY == 'True'}} - uses: actions/upload-artifact@v1 + uses: actions/upload-artifact@v4 with: - name: wheels - path: ./wheelhouse + name: wheels-${{ matrix.os }}-${{ matrix.python-version }} + path: ./wheelhouse \ No newline at end of file