github.com/ahjdzx/deis@v1.1.1/docs/conf.py (about)

     1  # -*- coding: utf-8 -*-
     2  #
     3  # deis documentation build configuration file, created by
     4  # sphinx-quickstart on Fri Jul 26 12:12:00 2013.
     5  #
     6  # This file is execfile()d with the current directory set to its containing dir.
     7  #
     8  # Note that not all possible configuration values are present in this
     9  # autogenerated file.
    10  #
    11  # All configuration values have a default; values that are commented out
    12  # serve to show the default.
    13  
    14  import os
    15  import sys
    16  
    17  # If extensions (or modules to document with autodoc) are in another directory,
    18  # add these directories to sys.path here. If the directory is relative to the
    19  # documentation root, use os.path.abspath to make it absolute, like shown here.
    20  
    21  # Some hackery here to get deis.py to be importable as client.deis
    22  open(os.path.join('..', '__init__.py'), 'a')
    23  sys.path.insert(0, os.path.abspath(os.path.join('..')))
    24  sys.path.insert(0, os.path.abspath(os.path.join('..', 'controller')))
    25  # create local_settings.py for SECRET_KEY if necessary
    26  local_settings_path = os.path.abspath(
    27      os.path.join('..', 'controller', 'deis', 'local_settings.py'))
    28  if not os.path.exists(local_settings_path):
    29      with open(local_settings_path, 'w') as local_settings:
    30          local_settings.write("SECRET_KEY = 'DummySecretKey'\n")
    31  # set up Django
    32  os.environ['DJANGO_SETTINGS_MODULE'] = 'deis.settings'
    33  from django.conf import settings  # noqa
    34  
    35  # -- General configuration -----------------------------------------------------
    36  
    37  # If your documentation needs a minimal Sphinx version, state it here.
    38  #needs_sphinx = '1.0'
    39  
    40  # Add any Sphinx extension module names here, as strings. They can be extensions
    41  # coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
    42  extensions = ['sphinx.ext.autodoc', 'sphinx.ext.autosummary',
    43                'sphinx.ext.viewcode']
    44  
    45  # default flags for auto-generated python code documetation
    46  autodoc_default_flags = ['members', 'undoc-members']
    47  
    48  # Add any paths that contain templates here, relative to this directory.
    49  templates_path = ['_templates']
    50  
    51  # The suffix of source filenames.
    52  source_suffix = '.rst'
    53  
    54  # The encoding of source files.
    55  #source_encoding = 'utf-8-sig'
    56  
    57  # The master toctree document.
    58  master_doc = 'toctree'
    59  
    60  # General information about the project.
    61  project = u'deis'
    62  copyright = u'2013, 2014 OpDemand LLC'
    63  
    64  # The version info for the project you're documenting, acts as replacement for
    65  # |version| and |release|, also used in various other places throughout the
    66  # built documents.
    67  #
    68  from deis import __version__
    69  
    70  # The short X.Y version.
    71  version = __version__.rsplit('.', 1)[0]
    72  # The full version, including alpha/beta/rc tags.
    73  release = __version__
    74  
    75  # The language for content autogenerated by Sphinx. Refer to documentation
    76  # for a list of supported languages.
    77  #language = None
    78  
    79  # There are two options for replacing |today|: either, you set today to some
    80  # non-false value, then it is used:
    81  #today = ''
    82  # Else, today_fmt is used as the format for a strftime call.
    83  #today_fmt = '%B %d, %Y'
    84  
    85  # List of patterns, relative to source directory, that match files and
    86  # directories to ignore when looking for source files.
    87  exclude_patterns = ['_build', 'venv', '**/_*.rst']
    88  
    89  # The reST default role (used for this markup: `text`) to use for all documents.
    90  #default_role = None
    91  
    92  # If true, '()' will be appended to :func: etc. cross-reference text.
    93  #add_function_parentheses = True
    94  
    95  # If true, the current module name will be prepended to all description
    96  # unit titles (such as .. function::).
    97  #add_module_names = True
    98  
    99  # If true, sectionauthor and moduleauthor directives will be shown in the
   100  # output. They are ignored by default.
   101  #show_authors = False
   102  
   103  # The name of the Pygments (syntax highlighting) style to use.
   104  pygments_style = 'sphinx'
   105  
   106  # A list of ignored prefixes for module index sorting.
   107  #modindex_common_prefix = []
   108  
   109  # If true, keep warnings as "system message" paragraphs in the built documents.
   110  #keep_warnings = False
   111  
   112  
   113  # -- Options for HTML output ---------------------------------------------------
   114  
   115  # The theme to use for HTML and HTML Help pages.  See the documentation for
   116  # a list of builtin themes.
   117  html_theme = 'deis'
   118  
   119  # Theme options are theme-specific and customize the look and feel of a theme
   120  # further.  For a list of options available for each theme, see the
   121  # documentation.
   122  #html_theme_options = {}
   123  
   124  # Add any paths that contain custom themes here, relative to this directory.
   125  html_theme_path = ['theme']
   126  
   127  # The name for this set of Sphinx documents.  If None, it defaults to
   128  # "<project> v<release> documentation".
   129  #html_title = None
   130  
   131  # A shorter title for the navigation bar.  Default is the same as html_title.
   132  #html_short_title = None
   133  
   134  # The name of an image file (relative to this directory) to place at the top
   135  # of the sidebar.
   136  #html_logo = None
   137  
   138  # The name of an image file (within the static path) to use as favicon of the
   139  # docs.  This file should be a Windows icon file (.ico) being 16x16 or 32x32
   140  # pixels large.
   141  #html_favicon = None
   142  
   143  # Add any paths that contain custom static files (such as style sheets) here,
   144  # relative to this directory. They are copied after the builtin static files,
   145  # so a file named "default.css" will overwrite the builtin "default.css".
   146  html_static_path = ['../controller/web/static']
   147  
   148  # If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
   149  # using the given strftime format.
   150  #html_last_updated_fmt = '%b %d, %Y'
   151  
   152  # If true, SmartyPants will be used to convert quotes and dashes to
   153  # typographically correct entities.
   154  html_use_smartypants = True
   155  
   156  html_add_permalinks = True
   157  
   158  # Custom sidebar templates, maps document names to template names.
   159  #html_sidebars = {}
   160  
   161  # Additional templates that should be rendered to pages, maps page names to
   162  # template names.
   163  #html_additional_pages = {}
   164  
   165  # If false, no module index is generated.
   166  #html_domain_indices = True
   167  
   168  # If false, no index is generated.
   169  #html_use_index = True
   170  
   171  # If true, the index is split into individual pages for each letter.
   172  #html_split_index = False
   173  
   174  # If true, links to the reST sources are added to the pages.
   175  #html_show_sourcelink = True
   176  
   177  # If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
   178  #html_show_sphinx = True
   179  
   180  # If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
   181  #html_show_copyright = True
   182  
   183  # If true, an OpenSearch description file will be output, and all pages will
   184  # contain a <link> tag referring to it.  The value of this option must be the
   185  # base URL from which the finished HTML is served.
   186  #html_use_opensearch = ''
   187  
   188  # This is the file name suffix for HTML files (e.g. ".xhtml").
   189  #html_file_suffix = None
   190  
   191  # Output file base name for HTML help builder.
   192  htmlhelp_basename = 'deisdoc'
   193  
   194  
   195  # -- Options for LaTeX output --------------------------------------------------
   196  
   197  latex_elements = {
   198      # The paper size ('letterpaper' or 'a4paper').
   199      #'papersize': 'letterpaper',
   200  
   201      # The font size ('10pt', '11pt' or '12pt').
   202      #'pointsize': '10pt',
   203  
   204      # Additional stuff for the LaTeX preamble.
   205      #'preamble': '',
   206  }
   207  
   208  # Grouping the document tree into LaTeX files. List of tuples
   209  # (source start file, target name, title, author, documentclass [howto/manual]).
   210  latex_documents = [
   211      ('index', 'deis.tex', u'deis Documentation',
   212       u'Author', 'manual'),
   213  ]
   214  
   215  # The name of an image file (relative to this directory) to place at the top of
   216  # the title page.
   217  #latex_logo = None
   218  
   219  # For "manual" documents, if this is true, then toplevel headings are parts,
   220  # not chapters.
   221  #latex_use_parts = False
   222  
   223  # If true, show page references after internal links.
   224  #latex_show_pagerefs = False
   225  
   226  # If true, show URL addresses after external links.
   227  #latex_show_urls = False
   228  
   229  # Documents to append as an appendix to all manuals.
   230  #latex_appendices = []
   231  
   232  # If false, no module index is generated.
   233  #latex_domain_indices = True
   234  
   235  
   236  # -- Options for manual page output --------------------------------------------
   237  
   238  # One entry per manual page. List of tuples
   239  # (source start file, name, description, authors, manual section).
   240  man_pages = [
   241      ('index', 'deis', u'deis Documentation',
   242       [u'Author'], 1)
   243  ]
   244  
   245  # If true, show URL addresses after external links.
   246  #man_show_urls = False
   247  
   248  
   249  # -- Options for Texinfo output ------------------------------------------------
   250  
   251  # Grouping the document tree into Texinfo files. List of tuples
   252  # (source start file, target name, title, author,
   253  #  dir menu entry, description, category)
   254  texinfo_documents = [
   255      ('index', 'deis', u'deis Documentation',
   256       u'Author', 'deis', 'One line description of project.',
   257       'Miscellaneous'),
   258  ]
   259  
   260  # Documents to append as an appendix to all manuals.
   261  #texinfo_appendices = []
   262  
   263  # If false, no module index is generated.
   264  #texinfo_domain_indices = True
   265  
   266  # How to display URL addresses: 'footnote', 'no', or 'inline'.
   267  #texinfo_show_urls = 'footnote'
   268  
   269  # If true, do not generate a @detailmenu in the "Top" node's menu.
   270  #texinfo_no_detailmenu = False
   271  
   272  
   273  # -- Options for Epub output ---------------------------------------------------
   274  
   275  # Bibliographic Dublin Core info.
   276  epub_title = u'deis'
   277  epub_author = u'OpDemand LLC'
   278  epub_publisher = u'OpDemand LLC'
   279  epub_copyright = u'2013, OpDemand LLC'
   280  
   281  # The language of the text. It defaults to the language option
   282  # or en if the language is not set.
   283  #epub_language = ''
   284  
   285  # The scheme of the identifier. Typical schemes are ISBN or URL.
   286  #epub_scheme = ''
   287  
   288  # The unique identifier of the text. This can be a ISBN number
   289  # or the project homepage.
   290  #epub_identifier = ''
   291  
   292  # A unique identification for the text.
   293  #epub_uid = ''
   294  
   295  # A tuple containing the cover image and cover page html template filenames.
   296  #epub_cover = ()
   297  
   298  # A sequence of (type, uri, title) tuples for the guide element of content.opf.
   299  #epub_guide = ()
   300  
   301  # HTML files that should be inserted before the pages created by sphinx.
   302  # The format is a list of tuples containing the path and title.
   303  #epub_pre_files = []
   304  
   305  # HTML files shat should be inserted after the pages created by sphinx.
   306  # The format is a list of tuples containing the path and title.
   307  #epub_post_files = []
   308  
   309  # A list of files that should not be packed into the epub file.
   310  #epub_exclude_files = []
   311  
   312  # The depth of the table of contents in toc.ncx.
   313  #epub_tocdepth = 3
   314  
   315  # Allow duplicate toc entries.
   316  #epub_tocdup = True
   317  
   318  # Fix unsupported image types using the PIL.
   319  #epub_fix_images = False
   320  
   321  # Scale large images.
   322  #epub_max_image_width = 0
   323  
   324  # If 'no', URL addresses will not be shown.
   325  #epub_show_urls = 'inline'
   326  
   327  # If false, no index is generated.
   328  #epub_use_index = True