Close pull requests targeting testing

This commit is contained in:
firestar5683
2026-11-25 21:52:03 -06:00
parent 542b4f463a
commit 7d3815dbb5
2 changed files with 12 additions and 1 deletions
+11
View File
@@ -11,6 +11,17 @@ jobs:
pull-requests: write
runs-on: ubuntu-latest
steps:
- name: Close pull requests targeting testing
if: github.repository == 'StarPilotHQ/StarPilot' && github.event.pull_request.base.ref == 'testing'
env:
GH_TOKEN: ${{ github.token }}
PR_NUMBER: ${{ github.event.pull_request.number }}
run: |
current=$(gh pr view "$PR_NUMBER" --repo "$GITHUB_REPOSITORY" --json baseRefName,state --jq '.baseRefName + ":" + .state')
if [ "$current" = testing:OPEN ]; then
gh pr close "$PR_NUMBER" --repo "$GITHUB_REPOSITORY" --comment 'Please retarget this pull request to `stable` and reopen it. Maintainers publish qualified changes to `testing`.'
fi
- uses: actions/checkout@v7
# Label PRs
+1 -1
View File
@@ -1 +1 @@
{"protected_inventory_sha256": "167f0e5159b94b878faf96c30505f35697f53ccf0a8176c73fe6c35aa759de6d", "schema_version": 1}
{"protected_inventory_sha256": "095109bd607c71f3da345edb95bd99894c414cd096012d6cfe626c5c8cef5353", "schema_version": 1}