Skip to content

Commit ffd7dac

Browse files
authored
gha: use native syntax to limit concurrency (#31)
1 parent d9a20c3 commit ffd7dac

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

.github/workflows/tests.yml

+5-8
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,12 @@ on:
77
branches: [main]
88
types: [opened, synchronize, reopened, ready_for_review]
99

10-
jobs:
11-
# Cancel previous running actions for the same PR
12-
cancel_previous:
13-
if: github.event.pull_request.draft == false
14-
runs-on: ubuntu-latest
15-
steps:
16-
- name: Cancel Workflow Action
17-
uses: styfle/[email protected]
10+
# Cancel previous running actions for the same PR
11+
concurrency:
12+
group: ${{ github.workflow }}-${{ github.ref }}
13+
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
1814

15+
jobs:
1916
checks:
2017
if: github.event.pull_request.draft == false
2118
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)