ci: permitir mais de um webhook do Discord por evento (#978)

Co-authored-by: Claude Opus 5.5 <[email protected]>
This commit is contained in:
Alessandro Akira Alves SaitoandClaude Opus 5.5 authored and GitHub committed 2026-10-22 21:49:41 -03:00
1 parent 003e42b6e0
commit 5abea3006e
1 file changed
+6 -2
+6 -2
View File
@@ -37,5 +37,9 @@ jobs:
esac
msg=${msg/opened/aberta}
# allowed_mentions vazio: título com @everyone não pinga ninguém
jq -n --arg c "$msg: **$TITLE**"$'\n'"$URL" '{content: $c, allowed_mentions: {parse: []}}' \
| curl -fsS -H 'Content-Type: application/json' -d @- "$hook"
body=$(jq -n --arg c "$msg: **$TITLE**"$'\n'"$URL" '{content: $c, allowed_mentions: {parse: []}}')
# o secret pode ter várias URLs separadas por espaço, uma por servidor
for h in $hook; do
curl -fsS -H 'Content-Type: application/json' -d "$body" "$h" || falhou=1
done
exit ${falhou:-0}