Skip to content

Commit

Permalink
chore: cancel previous GHA from the same PR (#162)
Browse files Browse the repository at this point in the history
  • Loading branch information
gregmagolan authored Feb 5, 2024
1 parent e2a3469 commit ff3298d
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions .github/workflows/default.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ on:
# Allows manually triggering this workflow from the Actions tab.
workflow_dispatch:

concurrency:
# Cancel previous actions from the same PR: https://stackoverflow.com/a/72408109
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
distros:
strategy:
Expand All @@ -19,7 +24,7 @@ jobs:
- ubuntu-22.04
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: bazelbuild/setup-bazelisk@v2
- name: Test
run: |
Expand All @@ -36,7 +41,7 @@ jobs:
- opt
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: bazelbuild/setup-bazelisk@v2
- name: Test
run: |
Expand All @@ -54,7 +59,7 @@ jobs:
- ubsan
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: bazelbuild/setup-bazelisk@v2
- name: Test ${{ matrix.sanitizer }}
run: |
Expand All @@ -65,7 +70,7 @@ jobs:
coverage:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: bazelbuild/setup-bazelisk@v2
- name: Test Coverage
run: |
Expand All @@ -82,7 +87,7 @@ jobs:
- macos-11
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: bazelbuild/setup-bazelisk@v2
- name: Test with RBE
run: |
Expand Down

0 comments on commit ff3298d

Please sign in to comment.