Skip to content

Commit

Permalink
Escape multiline changelog
Browse files Browse the repository at this point in the history
  • Loading branch information
seclerp committed Sep 30, 2022
1 parent ce093a2 commit 5e3254c
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,13 @@ jobs:

- name: 🏗 Get current changelog
id: changelog_step
run: >-
echo "::set-output name=CHANGELOG::$(
./gradlew getChangelog --console=plain -q
)"
run: |
CHANGELOG=$(./gradlew getChangelog --console=plain -q)
echo $CHANGELOG
CHANGELOG="${CHANGELOG//'%'/'%25'}"
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
CHANGELOG="${CHANGELOG//$'\r'/'%0D'}"
echo "::set-output name=CHANGELOG_ALL::$CHANGELOG"
- name: 🚀 Create Release
uses: ncipollo/release-action@v1
Expand All @@ -36,7 +39,7 @@ jobs:
commit: ${{ github.sha }} # Commit SHA
tag: v${{ env.PLUGIN_VERSION }} # 'v' + version from gradle.properties
draft: true
body: ${{ steps.changelog_step.outputs.CHANGELOG }}
body: ${{ steps.changelog_step.outputs.CHANGELOG_ALL }}
artifacts: "output/*.zip"
token: ${{ secrets.GITHUB_TOKEN }}

Expand Down

0 comments on commit 5e3254c

Please sign in to comment.