diff options
-rw-r--r-- | .gitignore | 3 | ||||
-rw-r--r-- | docs/conf.py | 60 | ||||
-rw-r--r-- | docs/index.rst | 15 | ||||
-rw-r--r-- | docs/requirements.txt | 1 | ||||
-rw-r--r-- | requirements-dev.txt | 1 | ||||
-rw-r--r-- | tox.ini | 6 |
6 files changed, 86 insertions, 0 deletions
@@ -40,6 +40,9 @@ htmlcov/ # Django stuff *.log +# Sphinx stuff +/docs/_build + # Vagrant stuff /.vagrant diff --git a/docs/conf.py b/docs/conf.py new file mode 100644 index 0000000..a46bea0 --- /dev/null +++ b/docs/conf.py @@ -0,0 +1,60 @@ +# -*- coding: utf-8 -*- +# +# Patchwork documentation build configuration file + +# -- General configuration ------------------------------------------------ + +# If your documentation needs a minimal Sphinx version, state it here. +# +needs_sphinx = '1.5' + +# Add any Sphinx extension module names here, as strings. They can be +# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom +# ones. +extensions = [] + +# Add any paths that contain templates here, relative to this directory. +templates_path = [] + +# The suffix(es) of source filenames. +# You can specify multiple suffix as a list of string: +# +# source_suffix = ['.rst', '.md'] +source_suffix = '.rst' + +# The master toctree document. +master_doc = 'index' + +# General information about the project. +project = u'Patchwork' +copyright = u'2017, Stephen Finucane' +author = u'Stephen Finucane' + +# 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. +# +# TODO(stephenfin): Eventually this should read the version programmatically +# +# The short X.Y version. +version = u'2.0-alpha' +# The full version, including alpha/beta/rc tags. +release = u'2.0-alpha' + +# The language for content autogenerated by Sphinx. Refer to documentation +# for a list of supported languages. +# +# This is also used if you do content translation via gettext catalogs. +# Usually you set "language" from the command line for these cases. +language = None + +# List of patterns, relative to source directory, that match files and +# directories to ignore when looking for source files. +# This patterns also effect to html_static_path and html_extra_path +exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] + +# The name of the Pygments (syntax highlighting) style to use. +pygments_style = 'sphinx' + +# If true, `todo` and `todoList` produce output, else they produce nothing. +todo_include_todos = False diff --git a/docs/index.rst b/docs/index.rst new file mode 100644 index 0000000..2a9ce05 --- /dev/null +++ b/docs/index.rst @@ -0,0 +1,15 @@ +Welcome to Patchwork's documentation! +===================================== + +.. toctree:: + :maxdepth: 2 + :caption: Contents: + + + +Indices and tables +================== + +* :ref:`genindex` +* :ref:`modindex` +* :ref:`search` diff --git a/docs/requirements.txt b/docs/requirements.txt new file mode 100644 index 0000000..add56d4 --- /dev/null +++ b/docs/requirements.txt @@ -0,0 +1 @@ +sphinx>=1.5 diff --git a/requirements-dev.txt b/requirements-dev.txt index 8f88605..ea548c0 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -2,3 +2,4 @@ Django>=1.8,<1.11 djangorestframework>=3.4,<3.7 django-filter>=1.0,<1.1 -r requirements-test.txt +-r docs/requirements.txt @@ -43,6 +43,12 @@ commands = flake8 {posargs} patchwork patchwork/bin/pwclient ignore = E129, F405 exclude = ./patchwork/migrations +[testenv:docs] +deps = + -r{toxinidir}/docs/requirements.txt +commands = + sphinx-build -W -b html docs docs/_build/html + [testenv:lint] basepython = python2.7 deps = |