conf.py 3.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. # -*- coding: utf-8 -*-
  2. #
  3. # Copyright (c) 2019-2021, Arm Limited. All rights reserved.
  4. #
  5. # SPDX-License-Identifier: BSD-3-Clause
  6. #
  7. #
  8. # Configuration file for the Sphinx documentation builder.
  9. #
  10. # See the options documentation at http://www.sphinx-doc.org/en/master/config
  11. import os
  12. # -- Project information -----------------------------------------------------
  13. project = 'Trusted Firmware-A'
  14. # -- General configuration ---------------------------------------------------
  15. # Add any Sphinx extension module names here, as strings. They can be
  16. # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
  17. # ones.
  18. extensions = ['myst_parser', 'sphinx.ext.autosectionlabel', 'sphinxcontrib.plantuml']
  19. # Add any paths that contain templates here, relative to this directory.
  20. templates_path = ['_templates']
  21. # The suffix(es) of source filenames.
  22. source_suffix = ['.md', '.rst']
  23. # The master toctree document.
  24. master_doc = 'index'
  25. # The language for content autogenerated by Sphinx. Refer to documentation
  26. # for a list of supported languages.
  27. #
  28. # This is also used if you do content translation via gettext catalogs.
  29. # Usually you set "language" from the command line for these cases.
  30. language = None
  31. # List of patterns, relative to source directory, that match files and
  32. # directories to ignore when looking for source files.
  33. # This pattern also affects html_static_path and html_extra_path .
  34. exclude_patterns = []
  35. # The name of the Pygments (syntax highlighting) style to use.
  36. pygments_style = 'sphinx'
  37. # Load the contents of the global substitutions file into the 'rst_prolog'
  38. # variable. This ensures that the substitutions are all inserted into each page.
  39. with open('global_substitutions.txt', 'r') as subs:
  40. rst_prolog = subs.read()
  41. # Minimum version of sphinx required
  42. needs_sphinx = '2.0'
  43. # -- Options for HTML output -------------------------------------------------
  44. # Don't show the "Built with Sphinx" footer
  45. html_show_sphinx = False
  46. # Don't show copyright info in the footer (we have this content in the page)
  47. html_show_copyright = False
  48. # The theme to use for HTML and HTML Help pages. See the documentation for
  49. # a list of builtin themes.
  50. html_theme = "sphinx_rtd_theme"
  51. # The logo to display in the sidebar
  52. html_logo = 'resources/TrustedFirmware-Logo_standard-white.png'
  53. # Options for the "sphinx-rtd-theme" theme
  54. html_theme_options = {
  55. 'collapse_navigation': False, # Can expand and collapse sidebar entries
  56. 'prev_next_buttons_location': 'both', # Top and bottom of the page
  57. 'style_external_links': True # Display an icon next to external links
  58. }
  59. # Path to _static directory
  60. html_static_path = ['_static']
  61. # Path to css file relative to html_static_path
  62. html_css_files = [
  63. 'css/custom.css',
  64. ]
  65. # -- Options for autosectionlabel --------------------------------------------
  66. # Only generate automatic section labels for document titles
  67. autosectionlabel_maxdepth = 1
  68. # -- Options for plantuml ----------------------------------------------------
  69. plantuml_output_format = 'svg_img'