mirror of
https://github.com/jazzband/django-downloadview.git
synced 2026-03-16 22:40:25 +00:00
Modified the way documentation version is retrieved, so that readthedocs.org can get it.
This commit is contained in:
parent
36e862d1c0
commit
d69b84a705
1 changed files with 7 additions and 3 deletions
10
docs/conf.py
10
docs/conf.py
|
|
@ -13,7 +13,11 @@
|
|||
|
||||
import sys, os
|
||||
|
||||
import django_downloadview
|
||||
|
||||
doc_dir = os.path.dirname(os.path.abspath(__file__))
|
||||
project_dir = os.path.dirname(doc_dir)
|
||||
version_filename = os.path.join(project_dir, 'VERSION')
|
||||
|
||||
|
||||
# If extensions (or modules to document with autodoc) are in another directory,
|
||||
# add these directories to sys.path here. If the directory is relative to the
|
||||
|
|
@ -51,9 +55,9 @@ copyright = u'2012, Benoît Bryon'
|
|||
# built documents.
|
||||
#
|
||||
# The short X.Y version.
|
||||
version = django_downloadview.__version__
|
||||
version = open(version_filename).read().strip()
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = django_downloadview.__version__
|
||||
release = version
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
|
|
|
|||
Loading…
Reference in a new issue