mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2025-12-20 22:00:06 +01:00
meson doesn't have configuration_data() in vcs_tag so we can only replace one string. sphinx cannot include things in-line. Since we want the git version to be replaced in random places, we need to put it into rst_prolog in conf.py - but that's where we neet to replace other things too. Work around this by generating a mini python module that returns the git version, then call that in conf.py. Side-bonus: we now have access to the full commit and the abbreviated commit. Not that anything actually uses this... Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
5 lines
108 B
Python
5 lines
108 B
Python
def get_git_version():
|
|
return "__GIT_VERSION__"[:7]
|
|
|
|
def get_git_version_full():
|
|
return "__GIT_VERSION__"
|