Skip to content

Commit

Permalink
refactor(ci): Make curl call more reliable by not using built in JSON…
Browse files Browse the repository at this point in the history
… helper of github actions
  • Loading branch information
Mikey Stengel committed Oct 11, 2024
1 parent 7a40b55 commit 05fc6e9
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions .github/workflows/editor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,16 @@ jobs:
if: steps.check_published.outputs.already_published == 'false'
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
RELEASE_VERSION: ${{ steps.get_version.outputs.version }}
run: |
curl -X POST \
-H "Authorization: token $GH_TOKEN" \
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/${{ github.repository }}/releases \
-d '{
"tag_name": "v${{ steps.get_version.outputs.version }}",
"name": "Serlo Editor - v${{ steps.get_version.outputs.version }}",
"body": ${{ toJson(env.RELEASE_NOTES) }}
}'
-d @- << EOF
{
"tag_name": "v${RELEASE_VERSION}",
"name": "Serlo Editor - v${RELEASE_VERSION}",
"body": $(echo "$RELEASE_NOTES" | jq -Rs .)
}
EOF

0 comments on commit 05fc6e9

Please sign in to comment.