Skip to content

Add GitHub workflows to auto-label PRs #3

Add GitHub workflows to auto-label PRs

Add GitHub workflows to auto-label PRs #3

---
name: Handle GitHub PR Review responses
on:
pull_request_review:
types:
- submitted
permissions:
pull-requests: write
jobs:
# Label PR as "waiting-author-response" when changes are requested
review-changes-requested:
runs-on: ubuntu-latest
if: github.event.review.state == 'changes_requested' && github.repository == 'stackhpc/stackhpc-kayobe-config'
steps:
- name: Update PR Labels
run: |
gh pr edit "$PR_NUMBER" --remove-label "waiting-review" || true
gh pr edit "$PR_NUMBER" --add-label "waiting-author-response"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
PR_NUMBER: ${{ github.event.pull_request.number }}