@@ -47,16 +47,27 @@ jobs:
47
47
run : |
48
48
if [[ "${{ github.event_name }}" == "pull_request_target" ]]; then
49
49
if [[ "${{ github.event.action }}" == "opened" ]]; then
50
- echo "type=opened" >> $GITHUB_OUTPUT
50
+ # Check if PR was opened and is not a draft
51
+ if [[ "${{ github.event.pull_request.draft }}" == "false" ]]; then
52
+ echo "type=opened" >> $GITHUB_OUTPUT
53
+ echo "type_ready=true" >> $GITHUB_OUTPUT
54
+ else
55
+ echo "type=opened" >> $GITHUB_OUTPUT
56
+ echo "type_ready=false" >> $GITHUB_OUTPUT
57
+ fi
51
58
elif [[ "${{ github.event.action }}" == "ready_for_review" ]]; then
52
59
echo "type=ready_for_review" >> $GITHUB_OUTPUT
60
+ echo "type_ready=true" >> $GITHUB_OUTPUT
53
61
elif [[ "${{ github.event.action }}" == "closed" && "${{ github.event.pull_request.merged }}" == "true" ]]; then
54
62
echo "type=merged" >> $GITHUB_OUTPUT
63
+ echo "type_ready=false" >> $GITHUB_OUTPUT
55
64
else
56
65
echo "type=other" >> $GITHUB_OUTPUT
66
+ echo "type_ready=false" >> $GITHUB_OUTPUT
57
67
fi
58
68
else
59
69
echo "type=other" >> $GITHUB_OUTPUT
70
+ echo "type_ready=false" >> $GITHUB_OUTPUT
60
71
fi
61
72
62
73
- name : Check if external contributor
@@ -150,7 +161,7 @@ jobs:
150
161
ready-for-review-comment :
151
162
name : Ready for Review Comment
152
163
needs : check-contributor
153
- if : needs.check-contributor.outputs.event_type == 'ready_for_review' && needs.check-contributor.outputs.is_external == 'true' && inputs.ready_for_review_comment != ''
164
+ if : ( needs.check-contributor.outputs.event_type == 'ready_for_review' || (needs.check-contributor.outputs.event_type == 'opened' && needs.check-contributor.outputs.type_ready == 'true')) && needs.check-contributor.outputs.is_external == 'true' && inputs.ready_for_review_comment != ''
154
165
runs-on : ubuntu-latest
155
166
steps :
156
167
- name : Leave ready for review comment
0 commit comments