Skip to content

Commit 933d08c

Browse files
authored
chore: skip bot accounts in community call reminders (hiero-ledger#1418)
Signed-off-by: Dominiq Barbero <mr.dom.barbero@gmail.com>
1 parent a4a4696 commit 933d08c

2 files changed

Lines changed: 9 additions & 5 deletions

File tree

.github/scripts/bot-community-calls.sh

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -81,13 +81,16 @@ EOF
8181
echo "$ISSUE_DATA" |
8282
jq -r '
8383
group_by(.author.login)
84+
| map(sort_by(.createdAt) | reverse | .[0])
8485
| .[]
85-
| sort_by(.createdAt)
86-
| reverse
87-
| .[0]
88-
| "\(.number) \(.author.login)"
86+
| "\(.number) \(.author.login) \(.author.__typename)"
8987
' |
90-
while read ISSUE_NUM AUTHOR; do
88+
while read -r ISSUE_NUM AUTHOR IS_BOT; do
89+
if [ "$IS_BOT" = "Bot" ]; then
90+
echo "Skipping issue #$ISSUE_NUM created by bot account @$AUTHOR"
91+
continue
92+
fi
93+
9194
for EXCLUDED in "${EXCLUDED_AUTHORS[@]}"; do
9295
if [ "$AUTHOR" = "$EXCLUDED" ]; then
9396
echo "Skipping issue #$ISSUE_NUM by excluded author @$AUTHOR"

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,7 @@ This changelog is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.
176176
- Fixed LinkBot permission issue for fork PRs by changing trigger to pull_request_target and adding proper permissions.
177177
- Fixed duplicate comment prevention in issue reminder bot by adding hidden HTML marker for reliable comment detection (.github/scripts/bot-issue-reminder-no-pr.sh) (#1372)
178178
- Fixed bot-pr-missing-linked-issue to skip commenting on pull requests created by automated bots. (#1382)
179+
- Updated `.github/scripts/bot-community-calls.sh` to skip posting reminders on issues created by bot accounts. (#1383)
179180

180181
### Breaking Change
181182

0 commit comments

Comments
 (0)