Skip to content

Commit

Permalink
Auto-cancel old builds when new commit pushed to branch (python#98009)
Browse files Browse the repository at this point in the history
* Auto-cancel old builds when new commit pushed to branch

* Add a fallback

Co-authored-by: Ezio Melotti <[email protected]>

* Use the same group for all workflows.

Co-authored-by: Ezio Melotti <[email protected]>
  • Loading branch information
2 people authored and mpage committed Oct 11, 2022
1 parent 1e204b1 commit 5723b53
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ on:
permissions:
contents: read

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
check_source:
name: 'Check for source changes'
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/build_msi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ on:
permissions:
contents: read

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
build:
name: Windows Installer
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/doc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ on:
permissions:
contents: read

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
build_doc:
name: 'Docs'
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/verify-ensurepip-wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ on:
permissions:
contents: read

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
verify:
runs-on: ubuntu-latest
Expand Down

0 comments on commit 5723b53

Please sign in to comment.