docs: cleanup for rtd
This commit is contained in:
+2
-17
@@ -6,10 +6,6 @@
|
|||||||
# -- Project information -----------------------------------------------------
|
# -- Project information -----------------------------------------------------
|
||||||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information
|
||||||
|
|
||||||
import os
|
|
||||||
import pathlib
|
|
||||||
|
|
||||||
import tomli
|
|
||||||
|
|
||||||
project = "SLS cSAXS"
|
project = "SLS cSAXS"
|
||||||
copyright = "2024, Paul Scherrer Institute"
|
copyright = "2024, Paul Scherrer Institute"
|
||||||
@@ -18,18 +14,6 @@ author = "Paul Scherrer Institute"
|
|||||||
# -- General configuration ---------------------------------------------------
|
# -- General configuration ---------------------------------------------------
|
||||||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
|
||||||
|
|
||||||
current_path = pathlib.Path(__file__).parent.parent.resolve()
|
|
||||||
version_path = f"{current_path}/pyproject.toml"
|
|
||||||
|
|
||||||
|
|
||||||
def get_version():
|
|
||||||
"""load the version from the version file"""
|
|
||||||
with open(version_path, "r", encoding="utf-8") as file:
|
|
||||||
res = tomli.loads(file.read())
|
|
||||||
return res["project"]["version"]
|
|
||||||
|
|
||||||
|
|
||||||
release = get_version()
|
|
||||||
|
|
||||||
extensions = [
|
extensions = [
|
||||||
"sphinx.ext.autodoc",
|
"sphinx.ext.autodoc",
|
||||||
@@ -79,4 +63,5 @@ language = "Python"
|
|||||||
html_theme = "pydata_sphinx_theme"
|
html_theme = "pydata_sphinx_theme"
|
||||||
html_static_path = ["_static"]
|
html_static_path = ["_static"]
|
||||||
html_css_files = ["custom.css"]
|
html_css_files = ["custom.css"]
|
||||||
# html_logo = "../bec_widgets/assets/app_icons/bec_widgets_icon.png"
|
# html_logo = "./assets/csaxs_icon.png"
|
||||||
|
html_title = "SLS cSAXS"
|
||||||
|
|||||||
Reference in New Issue
Block a user