@ -15,7 +15,14 @@
import sphinx_rtd_theme
import sys
import os
import git
def setup ( app ) :
app . add_config_value ( ' release_level ' , ' ' , ' env ' )
if not os . environ . get ( ' ENVOY_DOCS_RELEASE_LEVEL ' ) :
raise Exception ( " ENVOY_DOCS_RELEASE_LEVEL env var must be defined " )
release_level = os . environ [ ' ENVOY_DOCS_RELEASE_LEVEL ' ]
# 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
@ -30,8 +37,7 @@ import git
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [ ' sphinxcontrib.httpdomain ' , ' sphinx.ext.extlinks ' ]
extensions = [ ' sphinxcontrib.httpdomain ' , ' sphinx.ext.extlinks ' , ' sphinx.ext.ifconfig ' ]
extlinks = { ' repo ' : ( ' https://github.com/envoyproxy/envoy/blob/master/ %s ' , ' ' ) }
# Add any paths that contain templates here, relative to this directory.
@ -50,20 +56,20 @@ master_doc = 'index'
# General information about the project.
project = u ' envoy '
copyright = u ' 2016-2017, Lyft '
author = u ' Lyft '
copyright = u ' 2016-2017, Envoy Project Authors '
author = u ' Envoy Project Authors '
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.
repo = git . Repo ( ' ../../ ' )
last_commit = str ( repo . head . commit ) [ : 6 ]
if not os . environ . get ( ' ENVOY_DOCS_VERSION_STRING ' ) :
raise Exception ( " ENVOY_DOCS_VERSION_STRING env var must be defined " )
# The short X.Y version.
version = u ' 1.5.0- ' + last_commit
version = u ' 1.5.0- ' + os . environ [ ' ENVOY_DOCS_VERSION_STRING ' ]
# The full version, including alpha/beta/rc tags.
release = u ' 1.5.0- ' + last_commit
release = u ' 1.5.0- ' + os . environ [ ' ENVOY_DOCS_VERSION_STRING ' ]
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
@ -211,83 +217,3 @@ html_static_path = ['_static']
# Output file base name for HTML help builder.
htmlhelp_basename = ' envoydoc '
# -- Options for LaTeX output ---------------------------------------------
latex_elements = {
# The paper size ('letterpaper' or 'a4paper').
#'papersize': 'letterpaper',
# The font size ('10pt', '11pt' or '12pt').
#'pointsize': '10pt',
# Additional stuff for the LaTeX preamble.
#'preamble': '',
# Latex figure (float) alignment
#'figure_align': 'htbp',
}
# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title,
# author, documentclass [howto, manual, or own class]).
latex_documents = [
( master_doc , ' envoy.tex ' , u ' envoy Documentation ' ,
u ' Lyft ' , ' manual ' ) ,
]
# The name of an image file (relative to this directory) to place at the top of
# the title page.
#latex_logo = None
# For "manual" documents, if this is true, then toplevel headings are parts,
# not chapters.
#latex_use_parts = False
# If true, show page references after internal links.
#latex_show_pagerefs = False
# If true, show URL addresses after external links.
#latex_show_urls = False
# Documents to append as an appendix to all manuals.
#latex_appendices = []
# If false, no module index is generated.
#latex_domain_indices = True
# -- Options for manual page output ---------------------------------------
# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [
( master_doc , ' envoy ' , u ' envoy Documentation ' ,
[ author ] , 1 )
]
# If true, show URL addresses after external links.
#man_show_urls = False
# -- Options for Texinfo output -------------------------------------------
# Grouping the document tree into Texinfo files. List of tuples
# (source start file, target name, title, author,
# dir menu entry, description, category)
texinfo_documents = [
( master_doc , ' envoy ' , u ' envoy Documentation ' ,
author , ' envoy ' , ' One line description of project. ' ,
' Miscellaneous ' ) ,
]
# Documents to append as an appendix to all manuals.
#texinfo_appendices = []
# If false, no module index is generated.
#texinfo_domain_indices = True
# How to display URL addresses: 'footnote', 'no', or 'inline'.
#texinfo_show_urls = 'footnote'
# If true, do not generate a @detailmenu in the "Top" node's menu.
#texinfo_no_detailmenu = False