Skip to content

Commit a8df623

Browse files
authored
chore(ci): restrict each job concurrency except for main branch (#117)
- save some compute minutes 🌱 - Limit concurrency by workflow + ref (except for main branch)
1 parent 80bdfe7 commit a8df623

File tree

6 files changed

+24
-0
lines changed

6 files changed

+24
-0
lines changed

.github/workflows/go.yml

+4
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ on:
77
branches: [main, "release/**"]
88
workflow_dispatch:
99

10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.ref }}
12+
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
13+
1014
jobs:
1115
go_test_short:
1216
env:

.github/workflows/golangci-lint.yml

+4
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ permissions:
1313
# Optional: allow read access to pull request. Use with `only-new-issues` option.
1414
pull-requests: read
1515

16+
concurrency:
17+
group: ${{ github.workflow }}-${{ github.ref }}
18+
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
19+
1620
jobs:
1721
golangci:
1822
name: lint

.github/workflows/labels.yml

+4
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ on:
1111
- .github/labels.yml
1212
- .github/workflows/labels.yml
1313

14+
concurrency:
15+
group: ${{ github.workflow }}-${{ github.ref }}
16+
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
17+
1418
jobs:
1519
labeler:
1620
permissions:

.github/workflows/libevm-delta.yml

+4
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ on:
77
branches: [main, "release/**"]
88
workflow_dispatch:
99

10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.ref }}
12+
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
13+
1014
jobs:
1115
diffs:
1216
runs-on: ubuntu-latest

.github/workflows/rename-module.yml

+4
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ on:
99
type: string
1010
default: "2bd6bd01d2e8561dd7fc21b631f4a34ac16627a1"
1111

12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.ref }}
14+
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
15+
1216
jobs:
1317
rename-module:
1418
runs-on: ubuntu-latest

.github/workflows/yml.yml

+4
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ on:
99
- ".github/workflows/yml.yml"
1010
- ".github/yamllint.yml"
1111

12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.ref }}
14+
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
15+
1216
jobs:
1317
yaml-check:
1418
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)