Skip to content

Commit 150c3c1

Browse files
authored
Fix GH issue comment bot (#1217)
1 parent fc7c1ff commit 150c3c1

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

.github/workflows/comment-milestoned-issues.yaml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,15 @@ jobs:
2222
state: 'all',
2323
});
2424
25-
// Loop through the issues and if the issue was closed, post a comment referring to the new release
25+
// Loop through the issues and if the issue was closed and is not a PR,
26+
// post a comment referring to the new release
2627
for (const issue of issues.data) {
27-
if (issue.state === 'closed') {
28+
if (issue.state === 'closed' && !issue.pull_request) {
2829
await github.rest.issues.createComment({
2930
owner: context.repo.owner,
3031
repo: context.repo.repo,
3132
issue_number: issue.number,
32-
body: `> [!NOTE]\n> This issue has been implemented in the [new release of Activity Browser 🚀 (version ${milestone_title})](https://github.com/LCA-ActivityBrowser/activity-browser/releases/tag/${milestone_title}), you can get the new version by [updating Activity Browser](https://github.com/LCA-ActivityBrowser/activity-browser#updating-the-ab).\n> \n> Do you want to be notified of new releases of Activity Browser? [Subscribe](https://brightway.groups.io/g/AB-updates/join) to our [updates mailing list](https://brightway.groups.io/g/AB-updates/topics) ✉.\n\n🤖_beep boop! I'm a bot and this message was an automated action._\n_If updating does not make sense for this issue, just ignore this._`,
33+
body: `> [!NOTE]\n> This issue has been implemented in the [new release of Activity Browser 🚀 (version ${milestone_title})](https://github.com/LCA-ActivityBrowser/activity-browser/releases/tag/${milestone_title}), you can get the new version by [updating Activity Browser](https://github.com/LCA-ActivityBrowser/activity-browser#updating-the-ab).\n> \n> Do you want to be notified of new releases of Activity Browser? [Subscribe](https://brightway.groups.io/g/AB-updates/join) to our [updates mailing list](https://brightway.groups.io/g/AB-updates/topics) ✉.\n\n🤖 _beep boop! I'm a bot and this message was an automated action._\n_If updating does not make sense for this issue, just ignore this._`,
3334
});
3435
}
3536
}

0 commit comments

Comments
 (0)