summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrsiddharth <s@ricketyspace.net>2019-12-15 01:51:33 -0500
committerrsiddharth <s@ricketyspace.net>2019-12-15 01:51:33 -0500
commit58d80d4ef6a8aa60f6500a782cb17c4ad716412b (patch)
tree9875198d290eeebac35e22d10007331b495826aa
parentac6fb32022cb2bce4694e69896a8048b2b1f1dd5 (diff)
Makefile: Add archive.
* Makefile (VERSION): New variable (TARBALL): New variable. (PRD_WHEEL): Use VERSION for version. (archive): New target. (clean): Add archive/
-rw-r--r--Makefile17
1 files changed, 15 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 2ad6b69..de7962a 100644
--- a/Makefile
+++ b/Makefile
@@ -7,12 +7,16 @@
# This file is part of nfsw.
#
+VERSION=0.1.0
+
VENV_DIR=/usr/local/virtualenv/.nfsw
VENV_CMD=virtualenv-3
JSHINT=~/.npm-packages/bin/jshint
+TARBALL=nfsw-${VERSION}.tar.gz
+
PRD_HOST=vela
-PRD_WHEEL=nfsw-0.1.0-py3-none-any.whl
+PRD_WHEEL=nfsw-${VERSION}-py3-none-any.whl
ACME_CONF=etc/acme-client.conf
UWSGI_INI=etc/uwsgi/nfsw.ini
@@ -58,6 +62,15 @@ build:
python setup.py bdist_wheel
.PHONY: build
+
+archive:
+ mkdir -p archive \
+ && git archive --format=tar --prefix=nfsw-${VERSION}/ \
+ v${VERSION} | gzip > archive/${TARBALL} \
+ && gpg2 -sb --armor -o archive/${TARBALL}.sig archive/${TARBALL}
+.PHONY: archive
+
+
prd-init:
ssh root@${PRD_HOST} \\"echo 'https://cdn.openbsd.org/pub/OpenBSD' \
> /etc/installurl \
@@ -167,6 +180,6 @@ prd-tb:
.PHONY: prd-tb
clean:
- rm -rf build/ dist/ nfsw.egg-info/ instance
+ rm -rf build/ dist/ nfsw.egg-info/ instance archive/
find ./ -type d -name '__pycache__' -exec rm -rf {} +
.PHONY: clean