Skip to content

Commit 61ee85c

Browse files
mfranzkeCopilot
andauthored
refactor(dependabot): only run one concurrent pipeline (#4600)
* refactor(dependabot): only run one concurrent pipeline * refactor: corrected condition * Update .github/workflows/default.yml Co-authored-by: Copilot <[email protected]> --------- Co-authored-by: Copilot <[email protected]>
1 parent fbd7723 commit 61ee85c

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

.github/workflows/default.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,19 @@ on:
77
branches:
88
- "main"
99

10+
# We'd like to run the pipeline for Dependabot PRs sequentially, and all other PRs in parallel, but still only one action run for each PR.
1011
concurrency:
11-
group: ${{ github.workflow }}-${{ github.ref }}
12-
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
12+
group: >-
13+
${{
14+
github.actor == 'dependabot[bot]' &&
15+
'dependabot' ||
16+
format('{0}-{1}', github.workflow, github.ref)
17+
}}
18+
cancel-in-progress: >-
19+
${{
20+
github.actor != 'dependabot[bot]' &&
21+
github.ref != 'refs/heads/main'
22+
}}
1323
1424
jobs:
1525
init:

0 commit comments

Comments
 (0)