From b323f8e43e2173432369c0967ed38cb8a6564492 Mon Sep 17 00:00:00 2001 From: nodiscc Date: Tue, 24 Jan 2023 18:02:40 +0100 Subject: [PATCH] tools: github actions: prevent multiple concurrent workflow runs on the same branch/ref - cancel other pending/in-progress workflows if a new commit is pushed to the ref - ref. https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#concurrency --- .github/workflows/ci.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 707a96b..5ee1fd4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -8,6 +8,10 @@ on: env: GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} +concurrency: + group: ${{ github.ref }} + cancel-in-progress: true + jobs: test_run: runs-on: ubuntu-latest