Agunua is a Python library for the development of Gemini clients, by Stephane Bortzmeyer - stephane+frama@bortzmeyer.org https://framagit.org/bortzmeyer
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

33 lines
959 B

#!/bin/sh
set -e
VERSION=$(./agunua-cli --version)
if [ -z "$VERSION" ]; then
echo "No version found" >&2
exit 1
fi
if $(echo $VERSION | grep BETA > /dev/null); then
echo "Still a beta version ($VERSION)" >&2
exit 1
fi
VERSION2=$(python3 setup.py --version)
if [ "$VERSION" != "$VERSION2" ]; then
echo "$VERSION and $VERSION2 are different" >&2
exit 1
fi
if $(grep TODO CHANGES > /dev/null); then
echo "Still TODOs in CHANGES" >&2
exit 1
fi
PACKAGE=agunua
# git commit returns 1 if there is nothing to commit. We use
# diff-index to check that everything is committed
git diff-index --quiet HEAD || (echo "Uncommitted stuff" >&2; exit 1)
git tag release-${VERSION}
python3 setup.py sdist
gpg --detach-sign -a dist/${PACKAGE}-${VERSION}.tar.gz
twine upload dist/${PACKAGE}-${VERSION}.tar.gz dist/${PACKAGE}-${VERSION}.tar.gz.asc
# Deprecated:
# python3 setup.py upload --show-response --sign
git push origin release-${VERSION}