docs version uses VERSION file

This commit is contained in:
2026-08-30 23:39:07 -06:00
parent 3d91f3c235
commit c8e314b690

View File

@@ -45,14 +45,16 @@ master_doc = 'index'
project = u'ZoiteChat' project = u'ZoiteChat'
copyright = u'2026, TingPing' copyright = u'2026, TingPing'
# The version info for the project you're documenting, acts as replacement for # Read the release directly from the repository's VERSION file so the
# |version| and |release|, also used in various other places throughout the # documentation always matches the ZoiteChat source/release being built.
# built documents. _version_file = os.path.abspath(
# os.path.join(os.path.dirname(__file__), '..', 'VERSION')
# The short X.Y version. )
version = '2.19' with open(_version_file, encoding='utf-8') as version_file:
# The full version, including alpha/beta/rc tags. release = version_file.read().strip()
release = '2.19.0'
# The short X.Y version used by Sphinx.
version = '.'.join(release.split('.')[:2])
# The language for content autogenerated by Sphinx. Refer to documentation # The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages. # for a list of supported languages.