mirror of
https://github.com/enjoy-digital/litex.git
synced 2025-01-04 09:52:26 -05:00
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
1 changed files with 8 additions and 6 deletions
|
@ -36,12 +36,13 @@ def generate_svd(soc, buildpath, filename=None, name="soc", **kwargs):
|
|||
|
||||
|
||||
def generate_docs(soc, base_dir,
|
||||
project_name = "LiteX SoC Project",
|
||||
author = "Anonymous",
|
||||
sphinx_extensions = [],
|
||||
quiet = False,
|
||||
note_pulses = False,
|
||||
from_scratch = True):
|
||||
project_name = "LiteX SoC Project",
|
||||
author = "Anonymous",
|
||||
sphinx_extensions = [],
|
||||
quiet = False,
|
||||
note_pulses = False,
|
||||
from_scratch = True,
|
||||
sphinx_extra_config = ""):
|
||||
"""Possible extra extensions:
|
||||
[
|
||||
'm2r',
|
||||
|
@ -68,6 +69,7 @@ def generate_docs(soc, base_dir,
|
|||
sphinx_ext_str += "\n \"{}\",".format(ext)
|
||||
print(default_sphinx_configuration.format(project_name, year,
|
||||
author, author, sphinx_ext_str), file=conf)
|
||||
print(sphinx_extra_config, file=conf)
|
||||
|
||||
if not quiet:
|
||||
print("Generate the documentation by running `sphinx-build -M html {} {}_build`".format(base_dir, base_dir))
|
||||
|
|
Loading…
Reference in a new issue