From 44ef34db88818bbaf78bb617b024fc7eac9ca571 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Thu, 20 Oct 2022 19:08:26 +0200 Subject: [PATCH] doc/conf.py: read version number from meson.build --- doc/conf.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/doc/conf.py b/doc/conf.py index 0c50cecb7..95474259e 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -38,7 +38,9 @@ author = 'Max Kellermann' # built documents. # # The short X.Y version. -version = '0.23.10' +with open('../meson.build') as f: + import re + version = re.match(r".*version:\s*'([^']+)'", f.readline()).group(1) # The full version, including alpha/beta/rc tags. #release = version + '~git'