mirror of
https://github.com/catchorg/Catch2.git
synced 2025-09-18 02:45:40 +02:00
Add doxygen and graphviz support
This commit is contained in:
27
docs/conf.py
27
docs/conf.py
@@ -1,3 +1,9 @@
|
||||
import os
|
||||
import subprocess
|
||||
|
||||
from sphinx.application import Sphinx
|
||||
from pathlib import Path
|
||||
|
||||
project = 'Catch2'
|
||||
copyright = '2023, Martin Hořeňovský'
|
||||
author = 'Martin Hořeňovský'
|
||||
@@ -19,11 +25,28 @@ exclude_patterns = [
|
||||
]
|
||||
source_suffix = [".md"]
|
||||
|
||||
|
||||
html_theme = 'furo'
|
||||
#html_static_path = ['_static']
|
||||
# html_static_path = ['_static']
|
||||
|
||||
myst_enable_extensions = [
|
||||
"tasklist",
|
||||
"colon_fence",
|
||||
]
|
||||
|
||||
breathe_projects = {
|
||||
"Catch2": "build/doxygen/xml",
|
||||
}
|
||||
breathe_default_project = "Catch2"
|
||||
|
||||
|
||||
def generate_doxygen_xml(app: Sphinx):
|
||||
"""
|
||||
Run the doxygen commands
|
||||
"""
|
||||
os.chdir(Path(app.confdir).parent)
|
||||
subprocess.run(["doxygen"])
|
||||
|
||||
|
||||
def setup(app: Sphinx):
|
||||
# Add hook for building doxygen xml when needed
|
||||
app.connect("builder-inited", generate_doxygen_xml)
|
||||
|
Reference in New Issue
Block a user