Skip to content

Commit

Permalink
ci: replace cancel step with native concurrency pattern
Browse files Browse the repository at this point in the history
  • Loading branch information
pandatix committed Mar 1, 2024
1 parent 590d3bd commit 69fe145
Showing 1 changed file with 4 additions and 10 deletions.
14 changes: 4 additions & 10 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,13 @@ on: [push, pull_request]
permissions:
contents: read

jobs:
setup:
runs-on: ubuntu-latest
steps:
- name: Cancel previous
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}

jobs:
tests:
runs-on: ${{ matrix.platform }}
needs: [setup]
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand All @@ -43,7 +38,6 @@ jobs:

go-lint:
runs-on: ubuntu-latest
needs: [setup]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
Expand Down

0 comments on commit 69fe145

Please sign in to comment.