diff --git a/docs/source/conf.py b/docs/source/conf.py index c27f0bab3a..473e9c81a6 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -93,11 +93,20 @@ # built documents. # import act # noqa +import re # noqa + +# Extrac the version info and parse it +verinfo = act.__version__ + +if verinfo is None: + verinfo = "" + +parsed_version = re.search(r"(?P(?P\d+\.\d+)\.?\w*)", verinfo).groupdict() # The short X.Y version. -version = act.__version__ -# The full version, including alpha/beta/rc tags. -release = act.__version__ +version = parsed_version["base"] +if "+" in verinfo: + version += "dev" # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages.