From 4d962da67832d827fd1652037f74f0b47974067c Mon Sep 17 00:00:00 2001 From: Oleg Broytman Date: Wed, 25 Apr 2018 00:51:47 +0300 Subject: [PATCH] Build: Add release scripts --- devscripts/prerelease-tag | 4 ++++ devscripts/release | 25 +++++++++++++++++++++++++ 2 files changed, 29 insertions(+) create mode 100755 devscripts/prerelease-tag create mode 100755 devscripts/release diff --git a/devscripts/prerelease-tag b/devscripts/prerelease-tag new file mode 100755 index 0000000..19531f2 --- /dev/null +++ b/devscripts/prerelease-tag @@ -0,0 +1,4 @@ +#! /bin/sh + +tag="`python setup.py --version`" && +exec git tag --message="Release $tag" --sign $tag diff --git a/devscripts/release b/devscripts/release new file mode 100755 index 0000000..3076437 --- /dev/null +++ b/devscripts/release @@ -0,0 +1,25 @@ +#! /bin/sh + +cd "`dirname \"$0\"`"/.. && +umask 022 && +chmod -R a+rX . && +set-commit-date.py && + +python setup.py build_py && +python setup.py build --executable '/usr/bin/env python' && +python setup.py sdist && + +for py in 2.7 3.4 3.5 3.6; do + find build -name '*.py[co]' -delete && + python$py setup.py build_py && + python$py setup.py build --executable '/usr/bin/env python' && + python$py -m compileall build && + python$py -O -m compileall build && + python$py setup.py bdist_egg || exit 1 +done + +find build -name '*.py[co]' -delete && +python setup.py bdist_wheel --universal && + +twine upload dist/* && +exec rm -rf build dist m_librarian.egg-info -- 2.39.5