From a7c1f2a34ec5592597d7b09c4b240dfcf968273f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs?= Date: Thu, 17 Dec 2020 15:31:11 -0500 Subject: Add get_app_version and version --- youtube/__init__.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'youtube/__init__.py') diff --git a/youtube/__init__.py b/youtube/__init__.py index b27496d..f935f1e 100644 --- a/youtube/__init__.py +++ b/youtube/__init__.py @@ -1,4 +1,5 @@ from youtube import util +from .get_app_version import app_version import flask from flask import request import settings @@ -32,6 +33,10 @@ def inject_theme_preference(): return { 'theme_path': '/youtube.com/static/' + theme_names[settings.theme] + '.css', 'settings': settings, + # Detect version + 'current_version': app_version()['version'], + 'current_branch': app_version()['branch'], + 'current_commit': app_version()['commit'], } -- cgit v1.2.3