File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -267,6 +267,21 @@ jobs:
267267 --head "$BRANCH_NAME" \
268268 --base main
269269
270+ # Pushes made with GITHUB_TOKEN don't trigger other workflows.
271+ # Close/reopen the PR to generate a pull_request.reopened event,
272+ # which triggers required CI and enterprise audit workflows.
273+ - name : Trigger CI checks
274+ if : steps.final.outputs.success == 'true' && steps.validate.outputs.valid == 'true' && steps.changes.outputs.has-changes == 'true'
275+ env :
276+ GH_TOKEN : ${{ github.token }}
277+ BRANCH_NAME : ${{ steps.branch.outputs.branch }}
278+ run : |
279+ pr_number=$(gh pr list --head "$BRANCH_NAME" --json number --jq '.[0].number')
280+ if [ -n "$pr_number" ]; then
281+ gh pr close "$pr_number"
282+ gh pr reopen "$pr_number"
283+ fi
284+
270285 - name : Add job summary
271286 if : steps.final.outputs.success == 'true' && steps.validate.outputs.valid == 'true' && steps.changes.outputs.has-changes == 'true'
272287 env :
You can’t perform that action at this time.
0 commit comments