From 6ebc0758ba5365e94fd7ae3dc842089fdc00d5c9 Mon Sep 17 00:00:00 2001 From: Virgile Andreani Date: Mon, 4 Nov 2024 15:02:37 +0100 Subject: [PATCH] Cancel running workflows for updated PRs --- .github/workflows/tests.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 02b77feb1..3ad527204 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -7,6 +7,13 @@ on: - main + +# Cancel running workflows for updated PRs +# https://turso.tech/blog/simple-trick-to-save-environment-and-money-when-using-github-actions +concurrency: + group: ${{ github.workflow}}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + # Tests are split into multiple jobs to accelerate the CI. # Different jobs should be organized to take approximately the same # time to complete (and not be prohibitely slow).