summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Hellkamp <marc@gsites.de>2019-12-01 16:39:00 +0100
committerMarcel Hellkamp <marc@gsites.de>2019-12-01 16:39:00 +0100
commit6927a6bf365449ed1d423a2556c2e30210fcb678 (patch)
tree634a9b0f1b964b6461ca8f2959e5eab24d6ab347
parent774e1c7bbb67b813a38a5fa215dd3949289176ef (diff)
downloadbottle-6927a6bf365449ed1d423a2556c2e30210fcb678.tar.gz
Update build steps in makefile
-rw-r--r--Makefile25
1 files changed, 17 insertions, 8 deletions
diff --git a/Makefile b/Makefile
index 4e7aa9e..fccb1f4 100644
--- a/Makefile
+++ b/Makefile
@@ -1,16 +1,26 @@
PATH := build/python/bin:$(PATH)
VERSION = $(shell python setup.py --version)
ALLFILES = $(shell echo bottle.py test/*.py test/views/*.tpl)
+VENV = build/venv
.PHONY: release coverage install docs test test_all test_25 test_26 test_27 test_31 test_32 test_33 2to3 clean
-release: test_all
- python setup.py --version | egrep -q -v '[a-zA-Z]' # Fail on dev/rc versions
- git commit -e -m "Release of $(VERSION)" # Fail on nothing to commit
- git tag -a -m "Release of $(VERSION)" $(VERSION) # Fail on existing tags
- git push origin HEAD # Fail on out-of-sync upstream
- git push origin tag $(VERSION) # Fail on dublicate tag
- python setup.py sdist register upload # Release to pypi
+release: venv
+ $(VENV)/bin/python3 setup.py --version | egrep -q -v '[a-zA-Z]' # Fail on dev/rc versions
+ git commit -e -m "Release of $(VERSION)" # Fail on nothing to commit
+ git tag -a -m "Release of $(VERSION)" $(VERSION) # Fail on existing tags
+ git push origin HEAD # Fail on out-of-sync upstream
+ git push origin tag $(VERSION) # Fail on dublicate tag
+ $(VENV)/bin/python3 setup.py sdist bdist_wheel # Build project
+ $(VENV)/bin/twine upload # Release to pypi
+
+venv: $(VENV)/.installed
+$(VENV)/.installed: Makefile
+ python3 -mvenv $(VENV)
+ $(VENV)/bin/python3 -mensurepip
+ $(VENV)/bin/pip install -U pip
+ $(VENV)/bin/pip install -U setuptools wheel twine coverage
+ touch $(VENV)/.installed
coverage:
-mkdir build/
@@ -63,4 +73,3 @@ clean:
find . -name '*~' -exec rm -f {} +
find . -name '._*' -exec rm -f {} +
find . -name '.coverage*' -exec rm -f {} +
-