Skip to content

Commit

Permalink
fix concurrency for main branch jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
lihaoyi committed Jan 15, 2025
1 parent 1384582 commit 0063848
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,10 @@ on:
# cancel older runs of a pull request;
# this will not cancel anything for normal git pushes
concurrency:
group: cancel-old-pr-runs-${{ github.workflow }}-${{ github.ref_name }}
# * For runs on other repos, always use the `ref_name` so each branch only can have one concurrent run
# * For runs on `com-lihaoyi/mill`, use `head_ref` to allow one concurrent run per PR, but `run_id` to
# allow multiple concurrent runs in master
group: cancel-old-pr-runs-${{ github.workflow }}-${{ (github.repository != 'com-lihaoyi/mill' && github.ref_name) || (github.head_ref || github.run_id) }}
cancel-in-progress: true

jobs:
Expand Down

0 comments on commit 0063848

Please sign in to comment.