litex: add `sphinx_extra_config` to `generate_docs()`
This allows us to append additional strings to the sphinx `conf.py`. Signed-off-by: Sean Cross <sean@xobs.io>
This commit is contained in:
parent
7fecfbf8e0
commit
dd366467ed
|
@ -41,7 +41,8 @@ def generate_docs(soc, base_dir,
|
||||||
sphinx_extensions = [],
|
sphinx_extensions = [],
|
||||||
quiet = False,
|
quiet = False,
|
||||||
note_pulses = False,
|
note_pulses = False,
|
||||||
from_scratch = True):
|
from_scratch = True,
|
||||||
|
sphinx_extra_config = ""):
|
||||||
"""Possible extra extensions:
|
"""Possible extra extensions:
|
||||||
[
|
[
|
||||||
'm2r',
|
'm2r',
|
||||||
|
@ -68,6 +69,7 @@ def generate_docs(soc, base_dir,
|
||||||
sphinx_ext_str += "\n \"{}\",".format(ext)
|
sphinx_ext_str += "\n \"{}\",".format(ext)
|
||||||
print(default_sphinx_configuration.format(project_name, year,
|
print(default_sphinx_configuration.format(project_name, year,
|
||||||
author, author, sphinx_ext_str), file=conf)
|
author, author, sphinx_ext_str), file=conf)
|
||||||
|
print(sphinx_extra_config, file=conf)
|
||||||
|
|
||||||
if not quiet:
|
if not quiet:
|
||||||
print("Generate the documentation by running `sphinx-build -M html {} {}_build`".format(base_dir, base_dir))
|
print("Generate the documentation by running `sphinx-build -M html {} {}_build`".format(base_dir, base_dir))
|
||||||
|
|
Loading…
Reference in New Issue