Changeset 61135
- Timestamp:
- 11/04/2025 06:27:29 PM (5 weeks ago)
- File:
-
- 1 edited
-
trunk/.github/workflows/pull-request-comments.yml (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/.github/workflows/pull-request-comments.yml
r61050 r61135 131 131 const issue_number = Number( fs.readFileSync( './NR' ) ); 132 132 133 core.info( `Checking pull request #${issue_number}.` ); 134 135 // Confirm that the pull request is still open before leaving a comment. 136 const pr = await github.rest.pulls.get({ 137 owner: context.repo.owner, 138 repo: context.repo.repo, 139 pull_number: issue_number, 140 }); 141 142 if ( pr.data.state !== 'open' ) { 143 core.info( 'The pull request has been closed. No comment will be left.' ); 144 return; 145 } 146 133 147 // Comments are only added after the first successful build. Check for the presence of a comment and bail early. 134 148 const commentInfo = { … … 142 156 for ( const currentComment of comments ) { 143 157 if ( currentComment.user.type === 'Bot' && currentComment.body.includes( 'Test using WordPress Playground' ) ) { 158 core.info( 'A comment with instructions to test within a Playground instance already exists.' ); 144 159 return; 145 160 }
Note: See TracChangeset
for help on using the changeset viewer.