We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3e953ee commit 6ad6319Copy full SHA for 6ad6319
.github/workflows/staging-merge.yml
@@ -30,6 +30,20 @@ jobs:
30
with:
31
fetch-depth: 0
32
33
+ - name: Validate manual trigger is on staging branch
34
+ if: github.event_name == 'workflow_dispatch'
35
+ shell: bash
36
+ run: |
37
+ set -euo pipefail
38
+
39
+ CURRENT_BRANCH="${GITHUB_REF##*/}"
40
+ if [ "$CURRENT_BRANCH" != "staging" ]; then
41
+ echo "❌ Error: Manual workflow dispatch is only allowed on 'staging' branch"
42
+ echo " Current branch: $CURRENT_BRANCH"
43
+ exit 1
44
+ fi
45
+ echo "✓ Manual trigger validated on staging branch"
46
47
- name: Check if push is from merged PR
48
id: pr_merge_check
49
uses: actions/github-script@v7
0 commit comments