docs: get version from Versioneer, instead of hard-coding it
This commit is contained in:
parent
9d4c6aad3b
commit
c769ff7bbe
14
docs/conf.py
14
docs/conf.py
|
@ -58,10 +58,20 @@ author = u'Brian Warner'
|
|||
# |version| and |release|, also used in various other places throughout the
|
||||
# built documents.
|
||||
#
|
||||
def _get_versions():
|
||||
import os.path, sys, subprocess
|
||||
here = os.path.dirname(os.path.abspath(__file__))
|
||||
parent = os.path.dirname(here)
|
||||
v = subprocess.check_output([sys.executable, "setup.py", "--version"],
|
||||
cwd=parent)
|
||||
short = ".".join(v.split(".")[:2])
|
||||
long = v
|
||||
return short, long
|
||||
version, release = _get_versions()
|
||||
# The short X.Y version.
|
||||
version = u'0.10'
|
||||
#version = u'0.10'
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = u'0.10.3'
|
||||
#release = u'0.10.3'
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
|
|
Loading…
Reference in New Issue
Block a user