From 8e9f268fbd6060039403e30b489a233d24047d4d Mon Sep 17 00:00:00 2001 From: umarcor Date: Fri, 3 Mar 2023 14:34:17 +0100 Subject: doc/conf: add html_theme_options and html_css_files --- doc/conf.py | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'doc/conf.py') diff --git a/doc/conf.py b/doc/conf.py index dbe43d056..5c845c7f8 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -1,5 +1,6 @@ # -*- coding: utf-8 -*- import sys +from os import environ from os.path import abspath from pathlib import Path from json import loads as json_loads @@ -87,6 +88,28 @@ if ctx.is_file(): html_theme = "furo" +html_css_files = [ + "https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/fontawesome.min.css", + "https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/solid.min.css", + "https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/brands.min.css", +] + +html_theme_options = { + "source_repository": "https://github.com/ghdl/ghdl", + "source_branch": environ.get("GITHUB_REF_NAME", "main"), + "source_directory": "doc", + "footer_icons": [ + { + "name": "GitHub ghdl/ghdl", + "url": "https://github.com/ghdl/ghdl", + "html": "", + "class": "fa-solid fa-brands fa-github", + }, + ], +} + +html_title = release + html_static_path = ['_static'] # '/public' will contain the output from gnatdoc html_extra_path = [str(Path(__file__).resolve().parent.parent / 'public')] # FIXME: if not exist, create directory -- cgit v1.2.3 From 7e2fba9abe23e9b627423768dd33ec4886403ba5 Mon Sep 17 00:00:00 2001 From: umarcor Date: Fri, 3 Mar 2023 15:07:47 +0100 Subject: doc: extensions cleanup --- doc/conf.py | 3 --- 1 file changed, 3 deletions(-) (limited to 'doc/conf.py') diff --git a/doc/conf.py b/doc/conf.py index 5c845c7f8..cc84ade50 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -189,12 +189,9 @@ extensions = [ 'sphinx.ext.mathjax', 'sphinx.ext.ifconfig', 'sphinx.ext.viewcode', - # BuildTheDocs extensions 'btd.sphinx.autoprogram', - # Other extensions -# 'recommonmark', 'exec', 'sphinx_fontawesome', 'sphinx_autodoc_typehints', -- cgit v1.2.3