提交 5ce30d94 编写于 作者: I Ian Bicking

update version in setup.py

上级 ef63f2f4
......@@ -47,7 +47,22 @@ copyright = '2009, The Open Planning Project'
# built documents.
#
# The short X.Y version.
version = '0.6'
import re, os
version_re = re.compile(
r'version = "(.*?)"')
fp = open(os.path.join(os.path.dirname(os.path.dirname(os.path.abspath(__file__))),
'setup.py'))
version = None
for line in fp:
match = version_re.search(line)
if match:
release = match.group(1)
break
else:
raise Exception("Cannot find version in setup.py")
fp.close()
del re, os, line, fp, version_re
version = '.'.join(release.split('.')[:2])
# The full version, including alpha/beta/rc tags.
release = '0.6'
......
......@@ -6,7 +6,7 @@ else:
import os
version = '0.6'
version = "0.6.post1"
doc_dir = os.path.join(os.path.dirname(__file__), 'docs')
index_filename = os.path.join(doc_dir, 'index.txt')
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册