File tree Expand file tree Collapse file tree 1 file changed +10
-4
lines changed
Expand file tree Collapse file tree 1 file changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,8 @@ name: Auto Assign Reviewer
22
33on :
44 pull_request_target :
5- types : [opened, ready_for_review]
5+ types : [opened, ready_for_review, synchronize]
6+ workflow_dispatch : # Manual trigger for testing
67
78permissions :
89 pull-requests : write
@@ -27,12 +28,17 @@ jobs:
2728 pip install pyyaml
2829
2930 - name : Authenticate with GitHub
30- run : echo "${{ secrets.GH_PAT }}" | gh auth login --with-token
31- env :
32- GH_TOKEN : ${{ secrets.GH_PAT }}
31+ run : |
32+ if [ -z "${{ secrets.GH_PAT }}" ]; then
33+ echo "Error: GH_PAT secret is not set"
34+ exit 1
35+ fi
36+ # Use PAT directly without gh auth login
37+ echo "Using PAT for authentication"
3338
3439 - name : Assign reviewer
3540 env :
3641 PR_NUMBER : ${{ github.event.pull_request.number }}
42+ GH_TOKEN : ${{ secrets.GH_PAT }}
3743 run : |
3844 python .github/scripts/assign_reviewer.py
You can’t perform that action at this time.
0 commit comments