diff --git a/vcsserver/__init__.py b/vcsserver/__init__.py --- a/vcsserver/__init__.py +++ b/vcsserver/__init__.py @@ -17,13 +17,20 @@ import os +__version__ = '' + def get_version(): + global __version__ + if __version__: + return __version__ + here = os.path.abspath(os.path.dirname(__file__)) ver_file = os.path.join(here, "VERSION") with open(ver_file, "rt") as f: version = f.read().strip() + __version__ = version return version # link to config for pyramid