comparison setup.py @ 161:98a485512289

installation: fixed version in setup.py
author Goffi <goffi@goffi.org>
date Sat, 28 Apr 2018 11:04:17 +0200
parents 9d3d700a65b7
children c63922860f80
comparison
equal deleted inserted replaced
160:916af9c1cb9b 161:98a485512289
36 36
37 37
38 def cagou_dev_version(): 38 def cagou_dev_version():
39 """Use mercurial data to compute version""" 39 """Use mercurial data to compute version"""
40 def version_scheme(version): 40 def version_scheme(version):
41 return VERSION 41 return VERSION.replace('D', '.dev0')
42 42
43 def local_scheme(version): 43 def local_scheme(version):
44 # XXX: setuptools_scm seems buggy and the '+' and the '_' are replaced by '-' 44 return "+{rev}.{distance}".format(
45 # breaking the local version identifier scheme
46 # cf. https://github.com/pypa/setuptools_scm/issues/237
47 return "+{rev}_{distance}".format(
48 rev=version.node[1:], 45 rev=version.node[1:],
49 distance=version.distance) 46 distance=version.distance)
50 47
51 return {'version_scheme': version_scheme, 48 return {'version_scheme': version_scheme,
52 'local_scheme': local_scheme} 49 'local_scheme': local_scheme}