From c856a4efc95ab3031d9f3ee197ed54515df0fee6 Mon Sep 17 00:00:00 2001 From: Alexandru DAMIAN Date: Wed, 18 Feb 2015 18:28:18 +0000 Subject: bitbake: toaster: get proper version string This patch brings in the toaster tree commit ID in the version string to allow users properly report their toaster version when submitting issues. (Bitbake rev: 5cc87ee0ac3b2bd399e7f009dda9d6de87209a27) Signed-off-by: Alexandru DAMIAN Signed-off-by: Richard Purdie --- bitbake/lib/toaster/toastermain/settings.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'bitbake/lib/toaster/toastermain/settings.py') diff --git a/bitbake/lib/toaster/toastermain/settings.py b/bitbake/lib/toaster/toastermain/settings.py index b6a42c0626..a7304fa167 100644 --- a/bitbake/lib/toaster/toastermain/settings.py +++ b/bitbake/lib/toaster/toastermain/settings.py @@ -232,7 +232,8 @@ from os.path import dirname as DN SITE_ROOT=DN(DN(os.path.abspath(__file__))) import subprocess -TOASTER_VERSION = subprocess.Popen('cd %s; git branch | grep "^* " | tr -d "* "' % SITE_ROOT, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()[0] +TOASTER_VERSION = subprocess.Popen('git branch | grep "^* " | tr -d "* "', cwd = SITE_ROOT, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()[0] +TOASTER_VERSION += " " + subprocess.Popen('git rev-parse HEAD ', cwd = SITE_ROOT, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE).communicate()[0] ROOT_URLCONF = 'toastermain.urls' -- cgit v1.2.3-54-g00ecf