From 76c6c72272c2d6ca2903995a68de006b6e9eb188 Mon Sep 17 00:00:00 2001 From: Chris Date: Sat, 15 Nov 2025 14:30:04 -0800 Subject: [PATCH 1/2] Update staging deployment workflow - Don't run the workflow when a PR is merged - Cancel in progress workflow when the PR receive a new update. --- .github/workflows/staging-deploy.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/staging-deploy.yml b/.github/workflows/staging-deploy.yml index 78cf10a9..eeaad7eb 100644 --- a/.github/workflows/staging-deploy.yml +++ b/.github/workflows/staging-deploy.yml @@ -2,10 +2,14 @@ name: Staging Deployment on: pull_request_target: - types: [opened, reopened, synchronize] + types: [opened, reopened, synchronize, closed] jobs: deploy: + if: github.event.pull_request.merged != true + concurrency: + group: staging-${{ github.event.pull_request.number }} + cancel-in-progress: true runs-on: ubuntu-latest environment: staging steps: From 7ee44368e973c3c5df4740b74de201d14c8b93aa Mon Sep 17 00:00:00 2001 From: Chris Date: Sat, 15 Nov 2025 14:32:50 -0800 Subject: [PATCH 2/2] Add comment to clarify deployment condition in staging workflow --- .github/workflows/staging-deploy.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/staging-deploy.yml b/.github/workflows/staging-deploy.yml index eeaad7eb..28ba83cd 100644 --- a/.github/workflows/staging-deploy.yml +++ b/.github/workflows/staging-deploy.yml @@ -6,6 +6,7 @@ on: jobs: deploy: + # if the PR is merged, don't run the deployment if: github.event.pull_request.merged != true concurrency: group: staging-${{ github.event.pull_request.number }}