name: Enforce PR Source on: pull_request: branches: - main jobs: check-pr-source: runs-on: ubuntu-latest steps: - name: Enforce only staging → main run: | echo "head_ref: ${{ github.head_ref }}" echo "base_ref: ${{ github.base_ref }}" if [[ "${{ github.head_ref }}" != "staging" ]]; then echo "ERROR: Only 'staging' branch may create PRs into 'main'!" exit 1 fi