Skip to content

Commit

Permalink
add publish changelog check
Browse files Browse the repository at this point in the history
  • Loading branch information
miaucl committed Aug 31, 2024
1 parent 436d539 commit 1cbec7c
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,19 @@ jobs:
echo "Tag version ($TAG_VERSION) matches file version ($FILE_VERSION)."
fi
- name: Check changelog entry
run: |
if [ github.ref =~ 'refs/tags/[0-9]+\\.[0-9]+\\.[0-9]+$' ]; then
if ! grep -q "## $TAG_VERSION" CHANGELOG.md; then
echo "No changelog entry found for version $TAG_VERSION."
exit 1
else
echo "Changelog entry found for version $TAG_VERSION."
fi
else
echo "Pre-release tag, skipping changelog check"
fi
publish-to-pypi:
name: >-
Publish Python 🐍 distribution 📦 to PyPI
Expand Down

0 comments on commit 1cbec7c

Please sign in to comment.