Skip to content

Commit 1357926

Browse files
authored
Use concurrency for GitHub Actions workflow (#2652)
This PR ensures that only the last execution per branch always works, even when pushed multiple times in a row, for example. The older one is canceled. Refs: https://docs.github.com/en/actions/using-jobs/using-concurrency https://github.blog/changelog/2021-04-19-github-actions-limit-workflow-run-or-job-concurrency/
1 parent a0099fc commit 1357926

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ on:
1010
- '*'
1111
permissions:
1212
contents: read
13+
concurrency:
14+
group: ${{ github.workflow }}-${{ github.ref }}
15+
cancel-in-progress: true
1316

1417
jobs:
1518
rubocop:

0 commit comments

Comments
 (0)