From ac76040e4955524a2ad15992f9374311682864ec Mon Sep 17 00:00:00 2001 From: Carlos Santiago <5726971+csantiago132@users.noreply.github.com> Date: Tue, 29 Oct 2024 12:42:49 -0500 Subject: [PATCH] chore(ci): test concurrency workflows --- .github/workflows/ci.yml | 4 ---- .github/workflows/workflow.deploy.yml | 4 ++++ .github/workflows/workflow.document.yml | 4 ++++ .github/workflows/workflow.lint.yml | 4 ++++ .github/workflows/workflow.release.yml | 17 +++++++++-------- .github/workflows/workflow.test.yml | 4 ++++ 6 files changed, 25 insertions(+), 12 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 225425a..9d7b273 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,10 +11,6 @@ on: push: branches: - main - - alpha - - beta - - canary - - pre/rc jobs: lint: diff --git a/.github/workflows/workflow.deploy.yml b/.github/workflows/workflow.deploy.yml index 45b57ab..6283b15 100644 --- a/.github/workflows/workflow.deploy.yml +++ b/.github/workflows/workflow.deploy.yml @@ -1,3 +1,7 @@ +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + on: workflow_call: diff --git a/.github/workflows/workflow.document.yml b/.github/workflows/workflow.document.yml index 06912a4..92473f2 100644 --- a/.github/workflows/workflow.document.yml +++ b/.github/workflows/workflow.document.yml @@ -1,3 +1,7 @@ +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + on: workflow_call: diff --git a/.github/workflows/workflow.lint.yml b/.github/workflows/workflow.lint.yml index 5c3a3e2..02caef7 100644 --- a/.github/workflows/workflow.lint.yml +++ b/.github/workflows/workflow.lint.yml @@ -1,3 +1,7 @@ +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + on: workflow_call: diff --git a/.github/workflows/workflow.release.yml b/.github/workflows/workflow.release.yml index 6bb1f10..f8a06cb 100644 --- a/.github/workflows/workflow.release.yml +++ b/.github/workflows/workflow.release.yml @@ -1,3 +1,7 @@ +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + permissions: pull-requests: write contents: write @@ -11,14 +15,11 @@ jobs: runs-on: ubuntu-latest if: | ( - github.event_name == 'push' && - ( - github.ref == 'refs/heads/main' || - github.ref == 'refs/heads/alpha' || - github.ref == 'refs/heads/beta' || - github.ref == 'refs/heads/canary' || - github.ref == 'refs/heads/pre/rc' - ) + github.ref == 'refs/heads/main' || + github.ref == 'refs/heads/alpha' || + github.ref == 'refs/heads/beta' || + github.ref == 'refs/heads/canary' || + github.ref == 'refs/heads/pre/rc' ) steps: - name: Checkout diff --git a/.github/workflows/workflow.test.yml b/.github/workflows/workflow.test.yml index 32eecec..8e89134 100644 --- a/.github/workflows/workflow.test.yml +++ b/.github/workflows/workflow.test.yml @@ -1,3 +1,7 @@ +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + on: workflow_call: