Skip to content

Commit 140eacd

Browse files
authored
New Doc: docs/devguide/sphinx.rst (#261)
1 parent f20cd46 commit 140eacd

File tree

3 files changed

+61
-2
lines changed

3 files changed

+61
-2
lines changed

docs/devguide/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,4 @@ are used and how to set up a local development environment.
1919

2020
local-development-environment
2121
tox
22+
sphinx

docs/devguide/sphinx.rst

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
.. _sphinx:
2+
3+
======================
4+
Shpinx Documentation
5+
======================
6+
7+
:Release: |version|
8+
:Date: |today|
9+
10+
The plugin uses the :pypi:`sphinx_celery <sphinx_celery>` engine to generate the documentation.
11+
The documentation is written in reStructuredText format and is located in the ``docs`` directory of the repository.
12+
13+
.. contents::
14+
:local:
15+
:depth: 2
16+
17+
Building the documentation
18+
==========================
19+
20+
To build the documentation, use the :ref:`tox_docs` tox environment.
21+
22+
Live Documentation
23+
==================
24+
25+
To serve the documentation locally, use the :ref:`tox_docs-livehtml` tox environment.
26+
27+
Generate API Documentation
28+
==========================
29+
30+
To generate the API documentation, use the :ref:`tox_docs-apidoc` tox environment.
31+
32+
Linting the documentation
33+
=========================
34+
35+
To lint the documentation, use the :ref:`tox_lint` tox environment, or these Makefile commands::
36+
37+
make -C ./docs apicheck
38+
make -C ./docs linkcheck
39+
make -C ./docs configcheck
40+
41+
Makefile
42+
========
43+
44+
The docs are managed using the following Makefile:
45+
46+
.. literalinclude:: ../../docs/Makefile
47+
:language: make
48+
:caption: docs.Makefile
49+
:start-after: .PHONY: help
50+
:end-before: .PHONY: clean

docs/devguide/tox.rst

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ These configurations are used to define the base settings for the tox environmen
8383
:start-after: [testenv]
8484
:end-before: [testenv:xdist]
8585

86-
.. _env_xdist:
86+
.. _tox_xdist:
8787

8888
xdist
8989
=====
@@ -110,7 +110,7 @@ This environment is used to run the tests in parallel using both :pypi:`tox <tox
110110
It will run the test environments in parallel using the ``-p auto`` option from tox, and then run each environment itself in
111111
parallel using pytest-xdist with the ``-n auto`` option.
112112

113-
It is slightly more efficient than the :ref:`env_xdist` tox environment, but less stable due to high resource usage.
113+
It is slightly more efficient than the :ref:`tox_xdist` tox environment, but less stable due to high resource usage.
114114

115115
.. literalinclude:: ../../tox.ini
116116
:language: ini
@@ -143,6 +143,8 @@ To run this environment, use::
143143

144144
tox -e mypy
145145

146+
.. _tox_lint:
147+
146148
lint
147149
====
148150

@@ -191,6 +193,8 @@ To run this environment, use::
191193

192194
tox -e clean
193195

196+
.. _tox_docs:
197+
194198
docs
195199
====
196200

@@ -209,6 +213,8 @@ To run this environment, use::
209213

210214
tox -e docs
211215

216+
.. _tox_docs-livehtml:
217+
212218
docs-livehtml
213219
=============
214220

@@ -229,6 +235,8 @@ To run this environment, use::
229235

230236
tox -e docs-livehtml
231237

238+
.. _tox_docs-apidoc:
239+
232240
docs-apidoc
233241
===========
234242

0 commit comments

Comments
 (0)