Dulwich.io dulwich / 8706eed
Generate API docs in sphinx. Jelmer Vernooń≥ 21 days ago
5 changed file(s) with 34 addition(s) and 16 deletion(s). Raw diff Collapse all Expand all
22 PEP8 = pep8
33 FLAKE8 ?= flake8
44 SETUP = $(PYTHON) setup.py
5 PYDOCTOR ?= pydoctor
65 TESTRUNNER ?= unittest
76 RUNTEST = PYTHONHASHSEED=random PYTHONPATH=$(shell pwd)$(if $(PYTHONPATH),:$(PYTHONPATH),) $(PYTHON) -m $(TESTRUNNER) $(TEST_OPTIONS)
87 COVERAGE = python3-coverage
1110
1211 all: build
1312
14 doc:: pydoctor
1513 doc:: sphinx
1614
1715 sphinx::
1816 $(MAKE) -C docs html
19
20 pydoctor::
21 $(PYDOCTOR) --make-html -c dulwich.cfg
2217
2318 build::
2419 $(SETUP) build
3030 clean:
3131 -rm -rf $(BUILDDIR)/*
3232
33 html:
33 apidocs:
34 sphinx-apidoc -feM -s txt -o api ../dulwich
35
36 html: apidocs
3437 $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
3538 @echo
3639 @echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
3740
38 dirhtml:
41 dirhtml: apidocs
3942 $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
4043 @echo
4144 @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."
4245
43 pickle:
46 pickle: apidocs
4447 $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle
4548 @echo
4649 @echo "Build finished; now you can process the pickle files."
4750
48 json:
51 json: apidocs
4952 $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json
5053 @echo
5154 @echo "Build finished; now you can process the JSON files."
5255
53 htmlhelp:
56 htmlhelp: apidocs
5457 $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
5558 @echo
5659 @echo "Build finished; now you can run HTML Help Workshop with the" \
5760 ".hhp project file in $(BUILDDIR)/htmlhelp."
5861
59 qthelp:
62 qthelp: apidocs
6063 $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
6164 @echo
6265 @echo "Build finished; now you can run "qcollectiongenerator" with the" \
6568 @echo "To view the help file:"
6669 @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/dulwich.qhc"
6770
68 latex:
71 latex: apidocs
6972 $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
7073 @echo
7174 @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
7275 @echo "Run \`make all-pdf' or \`make all-ps' in that directory to" \
7376 "run these through (pdf)latex."
7477
75 changes:
78 changes: apidocs
7679 $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes
7780 @echo
7881 @echo "The overview file is in $(BUILDDIR)/changes."
0 This is the API documentation for Dulwich.
1
2 Module reference
3 ----------------
4
5 .. toctree::
6 :maxdepth: 3
7
8 modules
9
10 Indices:
11
12 * :ref:`modindex`
13 * :ref:`search`
2525
2626 # Add any Sphinx extension module names here, as strings. They can be
2727 # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
28 extensions = ['sphinx.ext.autodoc']
28 extensions = [
29 'sphinx.ext.autodoc',
30 'sphinx.ext.ifconfig',
31 'sphinx.ext.intersphinx',
32 'sphinx_epytext',
33 ]
2934 try:
3035 import rst2pdf
3136 if rst2pdf.version >= '0.16':
5055
5156 # General information about the project.
5257 project = u'dulwich'
53 copyright = u'2011, Jelmer Vernooij'
58 copyright = u'2011-2018 Jelmer Vernooń≥'
5459
5560 # The version info for the project you're documenting, acts as replacement for
5661 # |version| and |release|, also used in various other places throughout the
1111 Documentation
1212 =============
1313
14
1514 .. toctree::
1615 :maxdepth: 2
1716
1918 protocol
2019
2120 tutorial/index
21
22 api/index
2223
2324
2425 Changelog