ci: post PR artifact comments per build
This commit is contained in:
17
.github/workflows/comment-pr-artifacts.yml
vendored
17
.github/workflows/comment-pr-artifacts.yml
vendored
@@ -110,23 +110,6 @@ jobs:
|
|||||||
artifactsBlock,
|
artifactsBlock,
|
||||||
].join('\n');
|
].join('\n');
|
||||||
|
|
||||||
const comments = await github.paginate(
|
|
||||||
github.rest.issues.listComments,
|
|
||||||
{ owner, repo, issue_number: prNumber, per_page: 100 }
|
|
||||||
);
|
|
||||||
const existing = comments.find((comment) => (comment.body || '').includes(marker));
|
|
||||||
|
|
||||||
if (existing) {
|
|
||||||
await github.rest.issues.updateComment({
|
|
||||||
owner,
|
|
||||||
repo,
|
|
||||||
comment_id: existing.id,
|
|
||||||
body,
|
|
||||||
});
|
|
||||||
core.info(`Updated existing artifacts comment: ${existing.html_url}`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
const created = await github.rest.issues.createComment({
|
const created = await github.rest.issues.createComment({
|
||||||
owner,
|
owner,
|
||||||
repo,
|
repo,
|
||||||
|
|||||||
Reference in New Issue
Block a user