From 96addda550279a6489cc103527a746695ad399d6 Mon Sep 17 00:00:00 2001 From: Marco Date: Tue, 21 May 2024 11:23:18 +0200 Subject: [PATCH] Update doc configuration --- docs/__init__.py | 8 -------- docs/conf.py | 11 +++++++++-- 2 files changed, 9 insertions(+), 10 deletions(-) delete mode 100644 docs/__init__.py diff --git a/docs/__init__.py b/docs/__init__.py deleted file mode 100644 index a772c38..0000000 --- a/docs/__init__.py +++ /dev/null @@ -1,8 +0,0 @@ -import toml - -with open("pyproject.toml") as f: - config = toml.load(f) - -version = config["project"]["version"] - -__version__ = version \ No newline at end of file diff --git a/docs/conf.py b/docs/conf.py index 0e92290..eda415d 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,4 +1,4 @@ -from . import __version__ +import toml # Configuration file for the Sphinx documentation builder. # @@ -8,10 +8,17 @@ # -- Project information ----------------------------------------------------- # https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information +# Read version from pyproject.toml + +with open("pyproject.toml") as f: + config = toml.load(f) + +version = config["project"]["version"] + project = "NetcdfData Microservice" copyright = "2024, IHCantabria" author = "IHCantabria" -release = __version__ +release = version # -- General configuration --------------------------------------------------- # https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration