Skip to content

Update p-p.json

Update p-p.json #196

Workflow file for this run

name: Auto Merge PR
on:
pull_request:
types:
- opened
- synchronize
- labeled
- ready_for_review
- reopened
jobs:
auto-merge:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- name: Debug GitHub Context
run: |
echo "GitHub Event Context:"
echo "${{ toJson(github.event) }}"
- name: Verify PR Author
run: |
AUTHOR=${{ github.event.pull_request.user.login }}
echo "PR Author: $AUTHOR"
if [[ "$AUTHOR" != "whes1015" ]]; then
echo "PR author is not whes1015. Exiting."
exit 1
fi
- name: Checkout PR Branch
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.ref }}
- name: Set PR Number
run: |
PR_NUMBER=${{ github.event.pull_request.number }}
if [[ -z "$PR_NUMBER" ]]; then
echo "Error: Pull request number is empty!"
exit 1
fi
echo "PR Number: $PR_NUMBER"
- name: Auto merge pull request
run: |
PR_NUMBER=${{ github.event.pull_request.number }}
gh pr merge $PR_NUMBER --merge --auto --delete-branch || echo "Auto merge failed for PR #$PR_NUMBER"
env:
GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }}