File tree 4 files changed +20
-11
lines changed 4 files changed +20
-11
lines changed Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ mpl-run: &mpl-install
68
68
69
69
doc-run : &doc-build
70
70
name : Build documentation
71
- command : make O=-W html
71
+ command : make html
72
72
working_directory : doc
73
73
74
74
doc-bundle-run : &doc-bundle
Original file line number Diff line number Diff line change 2
2
#
3
3
4
4
# You can set these variables from the command line.
5
- SPHINXOPTS =
5
+ SPHINXOPTS = -W
6
6
SPHINXBUILD = python -msphinx
7
7
SPHINXPROJ = matplotlib
8
8
SOURCEDIR = .
Original file line number Diff line number Diff line change @@ -87,17 +87,24 @@ Other useful invocations include
87
87
# Build pdf docs.
88
88
make latexpdf
89
89
90
- You can build the documentation with several options:
90
+ The ``SPHINXOPTS `` variable is set to ``-W `` by default to turn warnings into
91
+ errors. To unset it, use
91
92
92
- * ``make O=-W html `` turns Sphinx warnings into errors. The continuous
93
- integration script uses this option.
94
- * ``make O=-j4 html `` (for example) runs a parallel build with 4 processes.
93
+ .. code-block :: sh
94
+
95
+ make SPHINXOPTS= html
96
+
97
+ You can use the ``O `` variable to set additional options:
98
+
99
+ * ``make O=-j4 html `` runs a parallel build with 4 processes.
95
100
* ``make O=-Dplot_formats=png:100 html `` saves figures in low resolution.
96
101
* ``make O=-Dplot_gallery=0 html `` skips the gallery build.
97
102
98
- Multiple options can be combined using e.g. ``make O='-W -j4 ...' html ``. On
99
- Windows, the option needs to be set as the ``SPHINXOPTS `` environment
100
- variable, e.g. ``set SPHINXOPTS=-W -j4 & make html ``.
103
+ Multiple options can be combined using e.g. ``make O='-j4 -Dplot_gallery=0'
104
+ html ``.
105
+
106
+ On Windows, options needs to be set as environment variables, e.g. ``set O=-W
107
+ -j4 & make html ``.
101
108
102
109
Writing new documentation
103
110
=========================
Original file line number Diff line number Diff line change @@ -10,6 +10,8 @@ if "%SPHINXBUILD%" == "" (
10
10
set SOURCEDIR = .
11
11
set BUILDDIR = build
12
12
set SPHINXPROJ = matplotlib
13
+ set SPHINXOPTS = -W
14
+ set O =
13
15
14
16
%SPHINXBUILD% > NUL 2 > NUL
15
17
if errorlevel 9009 (
@@ -26,11 +28,11 @@ if errorlevel 9009 (
26
28
27
29
if " %1 " == " " goto help
28
30
29
- %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS%
31
+ %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
30
32
goto end
31
33
32
34
:help
33
- %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS%
35
+ %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
34
36
35
37
:end
36
38
popd
You can’t perform that action at this time.
0 commit comments