Release #34
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
release: | |
types: | |
- created | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
steps: | |
- run: sudo apt install pcregrep | |
- uses: actions/checkout@v4 | |
# - name: Read changelog | |
# id: read-changelog | |
# run: | | |
# echo 'content<<EOF' >> $GITHUB_OUTPUT | |
# cat CHANGELOG.md >> $GITHUB_OUTPUT | |
# echo 'EOF' >> $GITHUB_OUTPUT | |
- name: Parse changelog | |
id: parse-changelog | |
run: | | |
regex='## \[${{ github.event.release.tag_name }}\].*\n\n((.|\n)+?)(?:## \[[0-9]+.[0-9]+.[0-9]+\])' | |
echo 'match<<EOF' >> $GITHUB_OUTPUT | |
pcregrep -M -o1 "$regex" ./CHANGELOG.md >> $GITHUB_OUTPUT | |
echo 'EOF' >> $GITHUB_OUTPUT | |
# uses: kaisugi/[email protected] | |
# id: regex-match | |
# with: | |
# text: ${{ steps.read-changelog.outputs.content }} | |
# regex: '## \[${{ github.event.release.tag_name }}\].*\n\n((.|\n)+?)(?:## \[[0-9]+.[0-9]+.[0-9]+\])' | |
# flags: gm | |
- name: Set release body | |
uses: softprops/action-gh-release@v2 | |
with: | |
body: ${{ steps.parse-changelog.outputs.match }} |