1
0
mirror of https://github.com/certbot/certbot.git synced 2026-01-26 07:41:33 +03:00

Update to include sanitization for JSON file

This commit is contained in:
Alexis
2023-03-07 12:42:39 -08:00
committed by GitHub
parent 9f5e666702
commit 6c22e29875

View File

@@ -18,8 +18,14 @@ jobs:
REPO: ${{ github.repository }}
USER: ${{ github.actor }}
TITLE: ${{ github.event.pull_request.title }}
run: |
echo "{\"text\":\"[$REPO] | [${TITLE//\"/\\\"} #$NUMBER]($PR_URL) was merged into master by $USER.\"}" > mattermost.json
run: |
jq --null-input \
--arg number "$NUMBER" \
--arg pr_url "$PR_URL" \
--arg repo "$REPO" \
--arg user "$USER" \
--arg title "$TITLE" \
'{ "text": "[\($repo)] | [\($title) #\($number)](\($pr_url)) was merged into master by \($user)" }' > mattermost.json
- uses: mattermost/action-mattermost-notify@master
env:
MATTERMOST_WEBHOOK_URL: ${{ secrets.MATTERMOST_MERGE_WEBHOOK }}