Skip to content

Commit

Permalink
fix: libraries file list json escaped
Browse files Browse the repository at this point in the history
  • Loading branch information
felixerdy committed Dec 20, 2024
1 parent c5cad3d commit 103d0dc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/release-arduino-lib-versions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@ jobs:
LIBRARIES_FILE=$(cat libraries.txt)
# Append the generated text with a heading
NEW_BODY="${RELEASE_BODY}\n\n## Libraries\n\n\`\`\`\n${LIBRARIES_FILE}\n\`\`\`"
# Append the generated text with a heading and escape special characters
NEW_BODY=$(echo -e "${RELEASE_BODY}\n\n## Libraries\n\n\`\`\`\n${LIBRARIES_FILE}\n\`\`\`" | jq -Rs .)
# Update the release body using GitHub API
curl -X PATCH \
-H "Authorization: Bearer $GITHUB_TOKEN" \
-H "Accept: application/vnd.github.v3+json" \
"${RELEASE_URL}" \
-d "{\"body\":\"${NEW_BODY}\"}"
-d "{\"body\":${NEW_BODY}}"

0 comments on commit 103d0dc

Please sign in to comment.