55SPHINXOPTS =
66SPHINXBUILD = sphinx-build
77PAPER =
8- BUILDDIR = _build
9- CURBRANCH = master
10- PYTHONPATH = $(PWD )
8+ BUILDDIR = build
119
1210# User-friendly check for sphinx-build
1311ifeq ($(shell which $(SPHINXBUILD ) >/dev/null 2>&1; echo $$? ) , 1)
@@ -17,11 +15,11 @@ endif
1715# Internal variables.
1816PAPEROPT_a4 = -D latex_paper_size=a4
1917PAPEROPT_letter = -D latex_paper_size=letter
20- ALLSPHINXOPTS = -d $(BUILDDIR ) /doctrees $(PAPEROPT_$(PAPER ) ) $(SPHINXOPTS ) .
18+ ALLSPHINXOPTS = -d $(BUILDDIR ) /doctrees $(PAPEROPT_$(PAPER ) ) $(SPHINXOPTS ) source
2119# the i18n builder cannot share the environment and doctrees with the others
22- I18NSPHINXOPTS = $(PAPEROPT_$(PAPER ) ) $(SPHINXOPTS ) .
20+ I18NSPHINXOPTS = $(PAPEROPT_$(PAPER ) ) $(SPHINXOPTS ) source
2321
24- .PHONY : help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext
22+ .PHONY : help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest coverage gettext
2523
2624help :
2725 @echo " Please use \` make <target>' where <target> is one of"
3230 @echo " json to make JSON files"
3331 @echo " htmlhelp to make HTML files and a HTML help project"
3432 @echo " qthelp to make HTML files and a qthelp project"
33+ @echo " applehelp to make an Apple Help Book"
3534 @echo " devhelp to make HTML files and a Devhelp project"
3635 @echo " epub to make an epub"
3736 @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
@@ -47,16 +46,13 @@ help:
4746 @echo " pseudoxml to make pseudoxml-XML files for display purposes"
4847 @echo " linkcheck to check all external links for integrity"
4948 @echo " doctest to run all doctests embedded in the documentation (if enabled)"
50-
49+ @echo " coverage to run coverage check of the documentation (if enabled) "
5150
5251clean :
5352 rm -rf $(BUILDDIR ) /*
54- rm -rf reference/*
55- rm -rf docs/api
5653
5754html :
58- mkdir -p _static _templates
59- PYTHONPATH=$(PYTHONPATH ) $(SPHINXBUILD ) -b html $(ALLSPHINXOPTS ) $(BUILDDIR ) /html
55+ $(SPHINXBUILD ) -b html $(ALLSPHINXOPTS ) $(BUILDDIR ) /html
6056 @echo
6157 @echo " Build finished. The HTML pages are in $( BUILDDIR) /html."
6258
@@ -91,17 +87,25 @@ qthelp:
9187 @echo
9288 @echo " Build finished; now you can run " qcollectiongenerator" with the" \
9389 " .qhcp project file in $( BUILDDIR) /qthelp, like this:"
94- @echo " # qcollectiongenerator $( BUILDDIR) /qthelp/pydra .qhcp"
90+ @echo " # qcollectiongenerator $( BUILDDIR) /qthelp/Pype9 .qhcp"
9591 @echo " To view the help file:"
96- @echo " # assistant -collectionFile $( BUILDDIR) /qthelp/pydra.qhc"
92+ @echo " # assistant -collectionFile $( BUILDDIR) /qthelp/Pype9.qhc"
93+
94+ applehelp :
95+ $(SPHINXBUILD ) -b applehelp $(ALLSPHINXOPTS ) $(BUILDDIR ) /applehelp
96+ @echo
97+ @echo " Build finished. The help book is in $( BUILDDIR) /applehelp."
98+ @echo " N.B. You won't be able to view it unless you put it in" \
99+ " ~/Library/Documentation/Help or install it in your application" \
100+ " bundle."
97101
98102devhelp :
99103 $(SPHINXBUILD ) -b devhelp $(ALLSPHINXOPTS ) $(BUILDDIR ) /devhelp
100104 @echo
101105 @echo " Build finished."
102106 @echo " To view the help file:"
103- @echo " # mkdir -p $$ HOME/.local/share/devhelp/pydra "
104- @echo " # ln -s $( BUILDDIR) /devhelp $$ HOME/.local/share/devhelp/pydra "
107+ @echo " # mkdir -p $$ HOME/.local/share/devhelp/Pype9 "
108+ @echo " # ln -s $( BUILDDIR) /devhelp $$ HOME/.local/share/devhelp/Pype9 "
105109 @echo " # devhelp"
106110
107111epub :
@@ -172,6 +176,11 @@ doctest:
172176 @echo " Testing of doctests in the sources finished, look at the " \
173177 " results in $( BUILDDIR) /doctest/output.txt."
174178
179+ coverage :
180+ $(SPHINXBUILD ) -b coverage $(ALLSPHINXOPTS ) $(BUILDDIR ) /coverage
181+ @echo " Testing of coverage in the sources finished, look at the " \
182+ " results in $( BUILDDIR) /coverage/python.txt."
183+
175184xml :
176185 $(SPHINXBUILD ) -b xml $(ALLSPHINXOPTS ) $(BUILDDIR ) /xml
177186 @echo
@@ -181,6 +190,3 @@ pseudoxml:
181190 $(SPHINXBUILD ) -b pseudoxml $(ALLSPHINXOPTS ) $(BUILDDIR ) /pseudoxml
182191 @echo
183192 @echo " Build finished. The pseudo-XML files are in $( BUILDDIR) /pseudoxml."
184-
185- versioned :
186- PYTHONPATH=$(PYTHONPATH ) sphinx-versioning -vv -l ./docs/conf.py build -r $(CURBRANCH ) ./docs/ docs/$(BUILDDIR ) /html/
0 commit comments