File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 44 workflows : ["CI"]
55 types :
66 - completed
7+ branches-ignore :
8+ - main
79
810permissions :
911 pull-requests : write
@@ -26,13 +28,14 @@ jobs:
2628 throw new Error('Expected one artifact')
2729 }
2830
31+ const pullNumber = context.payload.workflow_run.pull_requests[0].number;
2932 const artifactUrl = artifacts.data.artifacts[0].archive_download_url;
3033 const commentBody = `<!-- build-artifact-comment -->\n📦 Docs artifacts are ready: ${artifactUrl}`;
3134
3235 const comments = await github.rest.issues.listComments({
3336 owner: context.repo.owner,
3437 repo: context.repo.repo,
35- issue_number: context.issue.number,
38+ issue_number: pullNumber
3639 });
3740
3841 const botComment = comments.data.find(comment =>
5154 await github.rest.issues.createComment({
5255 owner: context.repo.owner,
5356 repo: context.repo.repo,
54- issue_number: context.issue.number ,
57+ issue_number: pullNumber ,
5558 body: commentBody
5659 });
5760 }
You can’t perform that action at this time.
0 commit comments