Fix PR build report lookup (#420)

Use standalone jq to filter paginated PR comments
This commit is contained in:
Kurt Himebauch authored and GitHub committed 2026-10-08 00:32:11 -04:00
1 parent 9d8ff9615f
commit e0fc8362b8
1 file changed
+2 -2
+2 -2
View File
@@ -312,8 +312,8 @@ jobs:
$NEXT
EOF
)
comment=$(gh api "repos/$GITHUB_REPOSITORY/issues/$PR_NUMBER/comments" --paginate --slurp \
--jq "[.[][] | select(.user.login == \"github-actions[bot]\") | select(.body | startswith(\"$mark\"))] | first // {}")
comment=$(gh api "repos/$GITHUB_REPOSITORY/issues/$PR_NUMBER/comments" --paginate --slurp | \
jq "[.[][] | select(.user.login == \"github-actions[bot]\") | select(.body | startswith(\"$mark\"))] | first // {}")
id=$(jq -r '.id // empty' <<<"$comment")
if [ -n "$id" ]; then
state=$(jq -r '.body | split("\n")[] | select(startswith("<!-- droiddeck-discord: ") and endswith(" -->"))' <<<"$comment")