Skip to content

Commit ae2a9ed

Browse files
committed
add concurrency
1 parent b56748c commit ae2a9ed

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

.github/workflows/build.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,20 @@ on:
1111
release:
1212
types: [ published ]
1313

14+
concurrency:
15+
cancel-in-progress: false
16+
# This creates different concurrency groups depending on the trigger
17+
# For PRs: uses the PR number (e.g., "build-pr-123")
18+
# For branch pushes: uses the branch name (e.g., "build-develop/feature-x")
19+
# For releases: uses the release tag plus a unique run ID so each release runs independently
20+
# For manual dispatches: uses a unique run ID so each dispatch runs independently
21+
group: ${{
22+
github.event_name == 'pull_request' && format('build-pr-{0}', github.event.pull_request.number) ||
23+
github.event_name == 'push' && format('build-{0}', github.ref) ||
24+
github.event_name == 'release' && format('build-release-{0}-{1}', github.event.release.tag_name, github.run_id) ||
25+
format('build-dispatch-{0}', github.run_id)
26+
}}
27+
1428
defaults:
1529
run:
1630
shell: bash

0 commit comments

Comments
 (0)