diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 82ae650..7aa0495 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -73,14 +73,17 @@ jobs: id: generate_release_notes run: | NEW_TAG="v${{ steps.get_version.outputs.VERSION }}" - LAST_TAG=${{ steps.get_last_tag.outputs.LAST_TAG }} - RELEASE_NOTES=$(git log $LAST_TAG...$NEW_TAG --pretty=format:"- %s" --reverse) - echo "RELEASE_NOTES=$RELEASE_NOTES" >> $GITHUB_OUTPUT + LAST_TAG=$(git describe --tags --abbrev=0 $NEW_TAG^) + # Ensure release notes do not cause format errors + RELEASE_NOTES=$(git log $LAST_TAG...$NEW_TAG --pretty=format:"- %s" --reverse | sed 's/%/%25/g; s/\r/%0D/g; s/\n/%0A/g') + echo "RELEASE_NOTES<> $GITHUB_OUTPUT + echo -e "$RELEASE_NOTES" >> $GITHUB_OUTPUT + echo "EOF" >> $GITHUB_OUTPUT - name: Create GitHub Release uses: softprops/action-gh-release@v1 with: name: "neuralnetlib ${{ steps.get_version.outputs.VERSION }}" - tag_name: ${{ steps.get_version.outputs.VERSION }} + tag_name: v${{ steps.get_version.outputs.VERSION }} body: ${{ steps.generate_release_notes.outputs.RELEASE_NOTES }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/setup.py b/setup.py index da0fa95..fd244ff 100644 --- a/setup.py +++ b/setup.py @@ -2,7 +2,7 @@ setup( name='neuralnetlib', - version='0.4.1', + version='1.0.0', author='Marc Pinet', description='A simple neural network library with only numpy as dependency', long_description=open('README.md', encoding="utf-8").read(),