Skip to content

Commit

Permalink
also push branch after bumping version
Browse files Browse the repository at this point in the history
  • Loading branch information
Evidlo committed Jul 30, 2024
1 parent 86312e9 commit 321c653
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,16 @@ dist:
release: lock dist
# check that changelog is updated. only look at first 3 parts of semver
version=$(version)
stripped=$$(echo $${version} | cut -d . -f -3)
stripped=$$(echo $${version} | cut -d . -f -3 | cut -d '-' -f 1)
if ! grep $${stripped} CHANGELOG.rst
then
echo "Changelog doesn't seem to be updated! Quitting..."
exit 1
fi
# generate release notes from changelog
awk "/---/{next}; /^$${stripped}/{next}; {print} ; /^$$/{exit}" CHANGELOG.rst > TMPNOTES
gh release create --latest --verify-tag v$(version) dist/pykeepass-$(version)* -F TMPNOTES
twine upload -u __token__ dist/pykeepass-$(version)*
gh release create --latest --verify-tag v$(version) dist/pykeepass-$(version)*

.PHONY: lock
lock:
Expand All @@ -36,9 +38,10 @@ tag:
git add requirements.txt
git add pyproject.toml
git add CHANGELOG.rst
git commit -m "bump version"
git commit -m "bump version" --allow-empty
git tag -a v$(version) -m "version $(version)"
git push --tags
git push

.PHONY: docs
docs:
Expand Down

0 comments on commit 321c653

Please sign in to comment.