Skip to content

Commit 508f29f

Browse files
committed
Setup Exhale to include Doxygen in Sphinx
1 parent 709017a commit 508f29f

File tree

5 files changed

+32
-2
lines changed

5 files changed

+32
-2
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ doc/tex/*.gitinfo
7171
doc/tex/*.synctex.gz
7272
doc/tex/*.pdf
7373
doc/tex/docs/*.aux
74+
doc/doxyoutput/
75+
doc/api/
7476

7577
### Ignore IDE files ###
7678
.vs/

doc/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,6 @@ Ensure you have [mamba](https://mamba.readthedocs.io/en/latest/installation.html
3434
To build the documentation for all releases and the master branch, run:
3535

3636
```sh
37-
sphinx-multiversion ./ ./build/
37+
sphinx-multiversion ./ ./build/ -D 'exhale_args.containmentFolder=${sourcedir}/api'
3838
```
3939

doc/conf.py

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@
3232
'sphinxcontrib.bibtex',
3333
'sphinx_multiversion',
3434
"myst_parser",
35+
'breathe',
36+
'exhale',
3537
]
3638

3739
# Bibliography
@@ -50,6 +52,28 @@
5052
smv_remote_whitelist = r"^origin$" # Use branches from remote origin
5153
smv_outputdir_format = '{ref.name}' # Use the branch/tag name
5254

55+
# Setup the breathe extension
56+
breathe_projects = {
57+
"CADET": "./doxyoutput/xml"
58+
}
59+
breathe_default_project = "CADET"
60+
61+
# Setup the exhale extension
62+
exhale_args = {
63+
# These arguments are required
64+
"containmentFolder": "./api",
65+
"rootFileName": "library_root.rst",
66+
"doxygenStripFromPath": "..",
67+
# Heavily encouraged optional argument (see docs)
68+
"rootFileTitle": "Library API",
69+
# Suggested optional arguments
70+
"createTreeView": True,
71+
# TIP: if using the sphinx-bootstrap-theme, you need
72+
# "treeViewIsBootstrap": True,
73+
"exhaleExecutesDoxygen": True,
74+
"exhaleDoxygenStdin": "INPUT = ../include"
75+
}
76+
5377
# Add any paths that contain templates here, relative to this directory.
5478
templates_path = ['_templates']
5579

doc/environment.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,13 @@ channels:
33
- conda-forge
44
dependencies:
55
- python=3.11
6+
- doxygen
67
- myst-parser
78
- sphinx
89
- sphinx-sitemap
910
- pip
1011
- pip:
12+
- breathe
13+
- exhale
1114
- sphinxcontrib-bibtex
1215
- sphinx_multiversion

doc/index.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,9 +101,10 @@ Please refer to the `list of contributors <https://github.com/modsim/CADET/blob/
101101
simulation/index
102102
interface/index
103103
.. examples/index
104+
api/library_root
104105
CADET-Match <https://cadet.github.io/CADET-Match/master/index.html>
105106
license
106107
zbibliography
107108
Legal notice <https://www.fz-juelich.de/portal/EN/Service/LegalNotice/_node.html>
108109

109-
110+
.. todolist::

0 commit comments

Comments
 (0)