Skip to content

Commit 0a46f00

Browse files
committed
refactor(dependabot): only run one concurrent pipeline
1 parent c5a3a54 commit 0a46f00

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: [main]
88
workflow_dispatch:
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: true
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
# Stage 1: Parallel analysis jobs (no build required)

0 commit comments

Comments
 (0)