Debian Codegraph @

doc/Makefile

raw symbols SCIP
1 # Makefile for Sphinx documentation
2 #
3
4 # You can set these variables from the command line.
5 # SPHINXOPTS = -j auto
6 SPHINXOPTS =
7 SPHINXBUILD ?= sphinx-build
8 PAPER =
9 BUILDDIR = _build
10 ifneq ($(EXAMPLES_PATTERN),)
11 EXAMPLES_PATTERN_OPTS := -D sphinx_gallery_conf.filename_pattern="$(EXAMPLES_PATTERN)"
12 endif
13
14 # Internal variables.
15 PAPEROPT_a4 = -D latex_paper_size=a4
16 PAPEROPT_letter = -D latex_paper_size=letter
17 ALLSPHINXOPTS = -T -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS)\
18 $(EXAMPLES_PATTERN_OPTS) .
19
20
21 .PHONY: help clean html dirhtml pickle json latex latexpdf changes linkcheck doctest optipng
22
23 all: html-noplot
24
25 help:
26 @echo "Please use \`make <target>' where <target> is one of"
27 @echo " html to make standalone HTML files"
28 @echo " dirhtml to make HTML files named index.html in directories"
29 @echo " pickle to make pickle files"
30 @echo " json to make JSON files"
31 @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
32 @echo " latexpdf to make LaTeX files and run them through pdflatex"
33 @echo " changes to make an overview of all changed/added/deprecated items"
34 @echo " linkcheck to check all external links for integrity"
35 @echo " doctest to run all doctests embedded in the documentation (if enabled)"
36
37 clean:
38 -rm -rf $(BUILDDIR)/*
39 -rm -rf auto_examples/
40 -rm -rf generated/*
41 -rm -rf modules/generated/
42
43 html:
44 # These two lines make the build a bit more lengthy, and the
45 # the embedding of images more robust
46 rm -rf $(BUILDDIR)/html/_images
47 #rm -rf _build/doctrees/
48 $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html/stable
49 @echo
50 @echo "Build finished. The HTML pages are in $(BUILDDIR)/html/stable"
51
52 html-noplot:
53 $(SPHINXBUILD) -D plot_gallery=0 -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html/stable
54 @echo
55 @echo "Build finished. The HTML pages are in $(BUILDDIR)/html/stable."
56
57 dirhtml:
58 $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
59 @echo
60 @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."
61
62 pickle:
63 $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle
64 @echo
65 @echo "Build finished; now you can process the pickle files."
66
67 json:
68 $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json
69 @echo
70 @echo "Build finished; now you can process the JSON files."
71
72 latex:
73 $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
74 @echo
75 @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
76 @echo "Run \`make' in that directory to run these through (pdf)latex" \
77 "(use \`make latexpdf' here to do that automatically)."
78
79 latexpdf:
80 $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
81 @echo "Running LaTeX files through pdflatex..."
82 make -C $(BUILDDIR)/latex all-pdf
83 @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."
84
85 changes:
86 $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes
87 @echo
88 @echo "The overview file is in $(BUILDDIR)/changes."
89
90 linkcheck:
91 $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
92 @echo
93 @echo "Link check complete; look for any errors in the above output " \
94 "or in $(BUILDDIR)/linkcheck/output.txt."
95
96 doctest:
97 $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
98 @echo "Testing of doctests in the sources finished, look at the " \
99 "results in $(BUILDDIR)/doctest/output.txt."
100
101 # download-data:
102 # python -c "from sklearn.datasets._lfw import _check_fetch_lfw; _check_fetch_lfw()"
103
104 # Optimize PNG files. Needs OptiPNG. Change the -P argument to the number of
105 # cores you have available, so -P 64 if you have a real computer ;)
106 optipng:
107 find _build auto_examples */generated -name '*.png' -print0 \
108 | xargs -0 -n 1 -P 4 optipng -o10
109
110 dist: html latexpdf
111 cp _build/latex/scikit-optimize.pdf _build/html/stable/_downloads/scikit-optimize-docs.pdf