.github: cancel CI run for stale PR commits (#34964)

Each commit on a PR kicks off a CI run. Those CI jobs run to the finish
regardless, even when new commits have been pushed which make them stale
and useless. This change attempts to cancel any previously running job
for the same PR.
This commit is contained in:
Sina M 2026-05-26 14:44:56 +02:00 committed by GitHub
parent cae4c5f93c
commit 5933fa4bbf
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -7,6 +7,11 @@ on:
- master - master
workflow_dispatch: workflow_dispatch:
# Free runner capacity by cancelling superseded PR runs.
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
jobs: jobs:
lint: lint:
name: Lint name: Lint