CI: cancel previous workflow runs when new commit is pushed

This commit is contained in:
Šarūnas Nejus 2025-08-02 19:27:15 +01:00
parent 15b0c052b6
commit 61755ada9b
No known key found for this signature in database
GPG key ID: DD28F6704DBE3435
2 changed files with 11 additions and 0 deletions

View file

@ -4,6 +4,12 @@ on:
push:
branches:
- master
concurrency:
# Cancel previous workflow run when a new commit is pushed to a feature branch
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
env:
PY_COLORS: 1

View file

@ -6,6 +6,11 @@ on:
branches:
- master
concurrency:
# Cancel previous workflow run when a new commit is pushed to a feature branch
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
env:
PYTHON_VERSION: 3.9