Skip to content

Commit 353bfbb

Browse files
committed
Add breathe bridge doxygen to sphinx
1 parent 23b3b5e commit 353bfbb

File tree

5 files changed

+23
-9
lines changed

5 files changed

+23
-9
lines changed

doc/doxygen_config.dox

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ MAN_LINKS = NO
297297
#---------------------------------------------------------------------------
298298
# Configuration options related to the XML output
299299
#---------------------------------------------------------------------------
300-
GENERATE_XML = NO
300+
GENERATE_XML = YES
301301
XML_OUTPUT = xml
302302
XML_PROGRAMLISTING = YES
303303
#---------------------------------------------------------------------------
@@ -345,7 +345,7 @@ CLASS_DIAGRAMS = NO
345345
MSCGEN_PATH =
346346
DIA_PATH =
347347
HIDE_UNDOC_RELATIONS = YES
348-
HAVE_DOT = YES
348+
HAVE_DOT = NO
349349
DOT_NUM_THREADS = 0
350350
DOT_FONTNAME = Helvetica
351351
DOT_FONTSIZE = 10

doc/requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@ sphinx-copybutton
44
sphinx-design
55
sphinx-inline-tabs
66
sphinxcontrib-bibtex
7+
breathe

doc/sphinx/api_manual/available_apis.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Available APIs
33
==============
44

5-
```{todo}
6-
Show the different APIs which are currently available in the world builder (temperature, composition and CPO. Others will be added as well.)
7-
```
5+
```{eval-rst}
6+
.. doxygenindex::
7+
:outline:
8+
```

doc/sphinx/conf.in.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
'sphinx_design',
4040
'sphinx_copybutton',
4141
'sphinxcontrib.bibtex',
42+
'breathe',
4243
]
4344

4445
bibtex_default_style = 'plain'
@@ -49,6 +50,7 @@
4950

5051
# Breathe Configuration
5152
breathe_default_project = "GWB"
53+
breathe_projects = {"GWB": "../doxygen/xml"}
5254

5355
# Add any paths that contain templates here, relative to this directory.
5456
templates_path = ['_templates']
@@ -87,4 +89,4 @@
8789
# Add any paths that contain custom static files (such as style sheets) here,
8890
# relative to this directory. They are copied after the builtin static files,
8991
# so a file named "default.css" will overwrite the builtin "default.css".
90-
html_static_path = ['@CMAKE_CURRENT_SOURCE_DIR@/sphinx/_static/']
92+
html_static_path = ['@CMAKE_CURRENT_SOURCE_DIR@/sphinx/_static/']

doc/sphinx/conf.py

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,18 @@
1010
# add these directories to sys.path here. If the directory is relative to the
1111
# documentation root, use os.path.abspath to make it absolute, like shown here.
1212
#
13-
# import os
14-
# import sys
13+
import os
14+
import sys
15+
import subprocess
1516
# sys.path.insert(0, os.path.abspath('.'))
1617

18+
# -- Run Doxygen first if this is a build on ReadTheDocs
19+
20+
read_the_docs_build = os.environ.get('READTHEDOCS', None) == 'True'
21+
22+
if read_the_docs_build:
23+
os.mkdir("../doxygen")
24+
subprocess.call('cd ../.. ; doxygen doc/doxygen_config.dox', shell=True)
1725

1826
# -- Project information -----------------------------------------------------
1927

@@ -38,6 +46,7 @@
3846
'sphinx_design',
3947
'sphinx_copybutton',
4048
'sphinxcontrib.bibtex',
49+
'breathe',
4150
]
4251

4352
bibtex_default_style = 'plain'
@@ -48,6 +57,7 @@
4857

4958
# Breathe Configuration
5059
breathe_default_project = "GWB"
60+
breathe_projects = {"GWB": "../doxygen/xml"}
5161

5262
# Add any paths that contain templates here, relative to this directory.
5363
templates_path = ['_templates']
@@ -86,4 +96,4 @@
8696
# Add any paths that contain custom static files (such as style sheets) here,
8797
# relative to this directory. They are copied after the builtin static files,
8898
# so a file named "default.css" will overwrite the builtin "default.css".
89-
html_static_path = ['_static/']
99+
html_static_path = ['_static/']

0 commit comments

Comments
 (0)