From 15e9c23fa0cbbaf5e8e2bd27f598135e9516e33b Mon Sep 17 00:00:00 2001 From: messense Date: Tue, 15 Mar 2022 20:47:39 +0800 Subject: [PATCH] Limit concurrency on GitHub Actions https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#concurrency --- .github/workflows/bench.yml | 4 ++++ .github/workflows/ci.yml | 4 ++++ .github/workflows/guide.yml | 4 ++++ 3 files changed, 12 insertions(+) diff --git a/.github/workflows/bench.yml b/.github/workflows/bench.yml index d6d673f6..162a26bd 100644 --- a/.github/workflows/bench.yml +++ b/.github/workflows/bench.yml @@ -4,6 +4,10 @@ on: - main pull_request: +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }} + cancel-in-progress: true + name: Benchmark jobs: diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 224c7c02..38807800 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,6 +6,10 @@ on: - main pull_request: +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }} + cancel-in-progress: true + env: CARGO_TERM_COLOR: always diff --git a/.github/workflows/guide.yml b/.github/workflows/guide.yml index d7566672..75216cde 100644 --- a/.github/workflows/guide.yml +++ b/.github/workflows/guide.yml @@ -8,6 +8,10 @@ on: release: types: [published] +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }} + cancel-in-progress: true + env: CARGO_TERM_COLOR: always