Skip to content

Commit 55b3991

Browse files
committed
implement make html-noplot
1 parent 06660ef commit 55b3991

File tree

3 files changed

+10
-1
lines changed

3 files changed

+10
-1
lines changed

doc/Makefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,11 @@ clean:
2828
show:
2929
@python -c "import webbrowser; webbrowser.open_new_tab('file://$(shell pwd)/build/html/index.html')"
3030

31+
html-noplot:
32+
$(SPHINXBUILD) -D plot_gallery=0 -b html $(SOURCEDIR) $(BUILDDIR)/html $(SPHINXOPTS) $(O)
33+
@echo
34+
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
35+
3136
# Catch-all target: route all unknown targets to Sphinx using the new
3237
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
3338
%: Makefile

doc/conf.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,7 @@ def matplotlib_reduced_latex_scraper(block, block_vars, gallery_conf,
188188
'junit': '../test-results/sphinx-gallery/junit.xml' if CIRCLECI else '',
189189
'matplotlib_animations': True,
190190
'min_reported_time': 1,
191+
'plot_gallery': 'True', # sphinx-gallery/913
191192
'reference_url': {'matplotlib': None},
192193
'remove_config_comments': True,
193194
'reset_modules': (

doc/devel/documenting_mpl.rst

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,10 @@ Other useful invocations include
6767

6868
.. code-block:: sh
6969
70+
# Build the html documentation, but skip generation of the gallery images to
71+
# save time.
72+
make html-noplot
73+
7074
# Delete built files. May help if you get errors about missing paths or
7175
# broken links.
7276
make clean
@@ -86,7 +90,6 @@ You can use the ``O`` variable to set additional options:
8690

8791
* ``make O=-j4 html`` runs a parallel build with 4 processes.
8892
* ``make O=-Dplot_formats=png:100 html`` saves figures in low resolution.
89-
* ``make O=-Dplot_gallery=0 html`` skips the gallery build.
9093

9194
Multiple options can be combined, e.g. ``make O='-j4 -Dplot_gallery=0'
9295
html``.

0 commit comments

Comments
 (0)