Skip to content

Commit

Permalink
Update publish.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
fonimus authored Apr 23, 2021
1 parent c3360e0 commit 7e0c493
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,16 @@ jobs:

- name: Update CHANGLOG.md
run: |
echo ${{ github.ref }}
echo ${{ github.repository }}
echo ${GITHUB_REF##*/}
export tag=echo ${GITHUB_REF##*/}
export changeLog=$(echo ${{ steps.changelog.outputs.changelog }} | sed -e "s/##/###/g")
export toImport="## [${{ github.ref }}](https://github.com/${{ github.repository }}/releases/tag/${{ github.ref }})\n\n$changeLog"
echo $toImport
sed "/^##/i $toImport\n" CHANGELOG.md
export toImport="## [$tag](https://github.com/${{ github.repository }}/releases/tag/$tag)\n\n$changeLog"
sed "/^##/i $toImport\n" CHANGELOG.md > CHANGELOG.md
cat CHANGELOG.md
- name: Add and commit
uses: EndBug/add-and-commit@v7.0.0
with:
branch: master
message: Add release ${GITHUB_REF##*/} in CHANGLOG.md
default_author: github-actions

0 comments on commit 7e0c493

Please sign in to comment.