Skip to content

Commit

Permalink
Merge pull request #1032 from dhermes/change-authors-in-sphinx
Browse files Browse the repository at this point in the history
Updating authors in Sphinx config.
  • Loading branch information
dhermes committed Aug 4, 2015
2 parents ecf0004 + 6065f6b commit 9f5b229
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,10 @@
# All configuration values have a default; values that are commented out
# serve to show the default.

from email import message_from_string
import os
from pkg_resources import get_distribution
import sys, os
import sys
import urllib

# If extensions (or modules to document with autodoc) are in another directory,
Expand Down Expand Up @@ -56,7 +58,8 @@
# built documents.
#
# The short X.Y version.
release = os.getenv('SPHINX_RELEASE', get_distribution('gcloud').version)
distro = get_distribution('gcloud')
release = os.getenv('SPHINX_RELEASE', distro.version)

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down Expand Up @@ -197,11 +200,13 @@
#'preamble': '',
}

metadata = distro.get_metadata(distro.PKG_INFO)
author = message_from_string(metadata).get('Author')
# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title, author, documentclass [howto/manual]).
latex_documents = [
('index', 'gcloud.tex', u'gCloud Documentation',
u'JJ Geewax', 'manual'),
author, 'manual'),
]

# The name of an image file (relative to this directory) to place at the top of
Expand Down Expand Up @@ -231,7 +236,7 @@
# (source start file, name, description, authors, manual section).
man_pages = [
('index', 'gcloud', u'gCloud Documentation',
[u'JJ Geewax'], 1)
[author], 1)
]

# If true, show URL addresses after external links.
Expand All @@ -245,7 +250,7 @@
# dir menu entry, description, category)
texinfo_documents = [
('index', 'gcloud', u'gCloud Documentation',
u'JJ Geewax', 'gcloud', 'Python API for Google Cloud.',
author, 'gcloud', 'Python API for Google Cloud.',
'Miscellaneous'),
]

Expand Down

0 comments on commit 9f5b229

Please sign in to comment.