Skip to content

Commit 1f93279

Browse files
committed
Use cancel-in-progress instead of styfle/cancel-workflow-action.
Compare google/guava#8542. Aside from the reasons listed there, I wonder if this would have avoided a flaky(?) failure that I saw today on #1441: ``` Run styfle/cancel-workflow-action@d07a454 with: access_token: *** ignore_sha: false all_but_latest: false force_cancel: false { eventName: 'pull_request', sha: 'ca5f660437c7f1489d511540cf8c6d047ea0edcf', headSha: 'a160145b17ff487adfa4519b087472e3d328088d', branch: 'zizdep', owner: 'google', repo: 'google-java-format', GITHUB_RUN_ID: '31412633123' } Found token: yes Error: self-signed certificate; if the root CA is installed locally, try running Node.js with --use-system-ca ```
1 parent ecba4fb commit 1f93279

1 file changed

Lines changed: 5 additions & 8 deletions

File tree

‎.github/workflows/ci.yml‎

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ on:
2525
permissions:
2626
contents: read
2727

28+
# Cancel in-progress runs for pull requests, but not for master branch pushes
29+
concurrency:
30+
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
31+
cancel-in-progress: true
32+
2833
jobs:
2934
test-OpenJDK:
3035
name: "JDK ${{ matrix.java }} on ${{ matrix.os }}"
@@ -49,10 +54,6 @@ jobs:
4954
runs-on: ${{ matrix.os }}
5055
continue-on-error: ${{ matrix.experimental }}
5156
steps:
52-
- name: Cancel previous
53-
uses: styfle/cancel-workflow-action@d07a454dad7609a92316b57b23c9ccfd4f59af66 # 0.13.1
54-
with:
55-
access_token: ${{ github.token }}
5657
- name: "Check out repository"
5758
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
5859
with:
@@ -89,10 +90,6 @@ jobs:
8990
runs-on: ${{ matrix.os }}
9091
continue-on-error: true
9192
steps:
92-
- name: Cancel previous
93-
uses: styfle/cancel-workflow-action@d07a454dad7609a92316b57b23c9ccfd4f59af66 # 0.13.1
94-
with:
95-
access_token: ${{ github.token }}
9693
- name: "Check out repository"
9794
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
9895
with:

0 commit comments

Comments
 (0)