From d82b2f226f23cbcf8f7b8cb5f817de5e37bdfce3 Mon Sep 17 00:00:00 2001 From: Jonathan Kelley Date: Wed, 19 Jul 2023 12:50:28 -0700 Subject: [PATCH] Kill previous CI jobs when new pushed --- .github/workflows/docs stable.yml | 4 ++++ .github/workflows/docs.yml | 4 ++++ .github/workflows/macos.yml | 4 ++++ .github/workflows/main.yml | 4 ++++ .github/workflows/miri.yml | 4 +++- .github/workflows/playwright.yml | 5 +++++ .github/workflows/windows.yml | 4 ++++ 7 files changed, 28 insertions(+), 1 deletion(-) diff --git a/.github/workflows/docs stable.yml b/.github/workflows/docs stable.yml index a2d4e2c07..069d4308a 100644 --- a/.github/workflows/docs stable.yml +++ b/.github/workflows/docs stable.yml @@ -3,6 +3,10 @@ name: docs stable on: workflow_dispatch: +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: build-deploy: runs-on: ubuntu-latest diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index dafe0384d..3a452e770 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -8,6 +8,10 @@ on: branches: - master +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: build-deploy: runs-on: ubuntu-latest diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index eef04d521..471bdd715 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -24,6 +24,10 @@ on: - lib.rs - Cargo.toml +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: test: if: github.event.pull_request.draft == false diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index b37e63aa4..a95af8574 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -27,6 +27,10 @@ on: - lib.rs - Cargo.toml +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: check: if: github.event.pull_request.draft == false diff --git a/.github/workflows/miri.yml b/.github/workflows/miri.yml index 0146e98bc..e8aab0732 100644 --- a/.github/workflows/miri.yml +++ b/.github/workflows/miri.yml @@ -38,7 +38,9 @@ env: # - tokio-stream/Cargo.toml # rust_min: 1.49.0 - +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true jobs: test: diff --git a/.github/workflows/playwright.yml b/.github/workflows/playwright.yml index 7fe524bb3..41fa92fa7 100644 --- a/.github/workflows/playwright.yml +++ b/.github/workflows/playwright.yml @@ -7,6 +7,11 @@ on: defaults: run: working-directory: ./playwright-tests + +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: test: if: github.event.pull_request.draft == false diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 368df1630..f5792cf1e 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -24,6 +24,10 @@ on: - lib.rs - Cargo.toml +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: test: if: github.event.pull_request.draft == false