blob: 4e8ac4905df347489d853bfd3ebdf7a1da8acf9f [file] [log] [blame]
Paul Beesley22994f72019-01-23 15:39:39 +00001# -*- coding: utf-8 -*-
2#
Harrison Mutai32df52d2023-06-05 12:26:28 +01003# Copyright (c) 2019-2023, Arm Limited. All rights reserved.
Paul Beesley22994f72019-01-23 15:39:39 +00004#
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
Paul Beesley606d8072019-03-13 13:58:02 +000012import os
13
Paul Beesley22994f72019-01-23 15:39:39 +000014# -- Project information -----------------------------------------------------
15
Harrison Mutai32df52d2023-06-05 12:26:28 +010016project = "Trusted Firmware-A"
Paul Beesley22994f72019-01-23 15:39:39 +000017
Paul Beesley22994f72019-01-23 15:39:39 +000018# -- General configuration ---------------------------------------------------
19
20# Add any Sphinx extension module names here, as strings. They can be
21# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
22# ones.
Harrison Mutai32df52d2023-06-05 12:26:28 +010023extensions = ["myst_parser", "sphinx.ext.autosectionlabel", "sphinxcontrib.plantuml"]
Paul Beesley22994f72019-01-23 15:39:39 +000024
25# Add any paths that contain templates here, relative to this directory.
Harrison Mutai32df52d2023-06-05 12:26:28 +010026templates_path = ["_templates"]
Paul Beesley22994f72019-01-23 15:39:39 +000027
28# The suffix(es) of source filenames.
Harrison Mutai32df52d2023-06-05 12:26:28 +010029source_suffix = [".md", ".rst"]
Paul Beesley22994f72019-01-23 15:39:39 +000030
31# The master toctree document.
Harrison Mutai32df52d2023-06-05 12:26:28 +010032master_doc = "index"
Paul Beesley22994f72019-01-23 15:39:39 +000033
34# The language for content autogenerated by Sphinx. Refer to documentation
35# for a list of supported languages.
36#
37# This is also used if you do content translation via gettext catalogs.
38# Usually you set "language" from the command line for these cases.
Boyan Karatotev39dea252022-10-27 11:56:40 +010039language = "en"
Paul Beesley22994f72019-01-23 15:39:39 +000040
41# List of patterns, relative to source directory, that match files and
42# directories to ignore when looking for source files.
43# This pattern also affects html_static_path and html_extra_path .
Boyan Karatotev4273e6b2022-10-27 11:28:23 +010044# Don't try to build the venv in case it's placed with the sources
45exclude_patterns = [".env", "env", ".venv", "venv"]
Paul Beesley22994f72019-01-23 15:39:39 +000046
47# The name of the Pygments (syntax highlighting) style to use.
Harrison Mutai32df52d2023-06-05 12:26:28 +010048pygments_style = "sphinx"
Paul Beesley22994f72019-01-23 15:39:39 +000049
Paul Beesley606d8072019-03-13 13:58:02 +000050# Load the contents of the global substitutions file into the 'rst_prolog'
51# variable. This ensures that the substitutions are all inserted into each page.
Harrison Mutai32df52d2023-06-05 12:26:28 +010052with open("global_substitutions.txt", "r") as subs:
53 rst_prolog = subs.read()
Paul Beesley22994f72019-01-23 15:39:39 +000054
Paul Beesley73e4bd72019-05-17 11:45:36 +010055# Minimum version of sphinx required
Harrison Mutai32df52d2023-06-05 12:26:28 +010056needs_sphinx = "2.0"
Paul Beesley73e4bd72019-05-17 11:45:36 +010057
Paul Beesley22994f72019-01-23 15:39:39 +000058# -- Options for HTML output -------------------------------------------------
59
60# Don't show the "Built with Sphinx" footer
61html_show_sphinx = False
62
63# Don't show copyright info in the footer (we have this content in the page)
64html_show_copyright = False
65
66# The theme to use for HTML and HTML Help pages. See the documentation for
67# a list of builtin themes.
68html_theme = "sphinx_rtd_theme"
69
70# The logo to display in the sidebar
Harrison Mutai32df52d2023-06-05 12:26:28 +010071html_logo = "resources/TrustedFirmware-Logo_standard-white.png"
Paul Beesley22994f72019-01-23 15:39:39 +000072
73# Options for the "sphinx-rtd-theme" theme
74html_theme_options = {
Harrison Mutai32df52d2023-06-05 12:26:28 +010075 "collapse_navigation": False, # Can expand and collapse sidebar entries
76 "prev_next_buttons_location": "both", # Top and bottom of the page
77 "style_external_links": True, # Display an icon next to external links
Paul Beesley22994f72019-01-23 15:39:39 +000078}
Paul Beesley73e4bd72019-05-17 11:45:36 +010079
Zelalem05fed522021-02-24 19:20:09 -060080# Path to _static directory
Harrison Mutai32df52d2023-06-05 12:26:28 +010081html_static_path = ["_static"]
Zelalem05fed522021-02-24 19:20:09 -060082
83# Path to css file relative to html_static_path
84html_css_files = [
Harrison Mutai32df52d2023-06-05 12:26:28 +010085 "css/custom.css",
Zelalem05fed522021-02-24 19:20:09 -060086]
87
Paul Beesley73e4bd72019-05-17 11:45:36 +010088# -- Options for autosectionlabel --------------------------------------------
89
90# Only generate automatic section labels for document titles
Paul Beesley8c178b52019-07-12 11:56:58 +010091autosectionlabel_maxdepth = 1
92
93# -- Options for plantuml ----------------------------------------------------
94
Harrison Mutai32df52d2023-06-05 12:26:28 +010095plantuml_output_format = "svg_img"