[DOC] Modified conf.py to fetch the latest tag automatically

Closes-Bug: 1611957
Change-Id: Ia0efaa57addb9ce1dee05509260e6694874a4104
This commit is contained in:
root 2016-08-10 22:23:24 +00:00 committed by root
parent e940d3caf2
commit b921676523
2 changed files with 6 additions and 2 deletions

View File

@ -25,7 +25,7 @@
import openstackdocstheme
import os
import pbr.version
from subprocess import Popen, PIPE
# 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
# documentation root, use os.path.abspath to make it absolute, like shown here.
@ -297,3 +297,7 @@ pdf_documents = [
(master_doc, target_name,
title, author)
]
pipe = Popen('git describe --abbrev=0 --tags', stdout=PIPE, shell=True)
version = pipe.stdout.read()
rst_epilog = '.. |my_conf_val| replace:: %s' % version

View File

@ -66,7 +66,7 @@ Install the source and dependencies for the deployment host.
# git clone -b TAG https://github.com/openstack/openstack-ansible.git /opt/openstack-ansible
Replace ``TAG`` with the current stable release tag.
Replace ``TAG`` with the current stable release tag : |my_conf_val|
#. Change to the ``/opt/openstack-ansible`` directory, and run the
Ansible bootstrap script: