From 559f1d6fb1cf39ae714e5c8bc9c1c4ac72cf604d Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Sun, 8 Apr 2018 00:57:47 +0100 Subject: [PATCH] Move to tag-versioning. --- wscript | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/wscript b/wscript index 4676b2bd..b6271e5a 100644 --- a/wscript +++ b/wscript @@ -38,7 +38,15 @@ import distutils.spawn from waflib import Logs, Context APPNAME = 'libdcp' -VERSION = '1.5.1devel' + +this_version = subprocess.Popen(shlex.split('git tag -l --points-at HEAD'), stdout=subprocess.PIPE).communicate()[0] +last_version = subprocess.Popen(shlex.split('git describe --tags --abbrev=0'), stdout=subprocess.PIPE).communicate()[0] + +if this_version == '': + VERSION = '%sdevel' % last_version[1:].strip() +else: + VERSION = this_version[1:].strip() + API_VERSION = '-1.0' def options(opt): -- 2.30.2