Skip to content

Commit

Permalink
fix create release notes step
Browse files Browse the repository at this point in the history
  • Loading branch information
denco committed Apr 15, 2021
1 parent 3a7c484 commit b21ee44
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,14 @@ jobs:
run: echo "::set-output name=version::${GITHUB_REF#refs/*/}"
id: release-version
- name: Create release notes for version ${{ steps.release-version.outputs.version }}
run: npm run --silent changelog > RELEASE_NOTES_${{ steps.release-version.outputs.version }}.md
# run: npm run --silent changelog > RELEASE_NOTES_${{ steps.release-version.outputs.version }}.md
run: |
if [ $((grep $(grep -m1 'version' package.json | cut -d '"' -f 4) -n CHANGELOG.md || echo 0) | cut -d ':' -f 1) -eq 3 ]; then \
awk '/##/{++c;next} c==1' CHANGELOG.md | awk '!/^$/'; \
else \
>&2 echo 'Unchecked version'; \
echo 1; \
fi > RELEASE_NOTES_${{ steps.release-version.outputs.version }}.md
# https://github.com/ncipollo/release-action
- name: Create github release
uses: ncipollo/release-action@v1
Expand Down

0 comments on commit b21ee44

Please sign in to comment.