[Bf-blender-cvs] [46684d1] master: Initial tweaks to buildbot configuration

Sergey Sharybin noreply at git.blender.org
Tue Nov 19 10:01:41 CET 2013


Commit: 46684d1ad2a9ea6c6eea2a2e4baf3c7c4aa3ecb5
Author: Sergey Sharybin
Date:   Tue Nov 19 15:01:00 2013 +0600
http://developer.blender.org/rB46684d1ad2a9ea6c6eea2a2e4baf3c7c4aa3ecb5

Initial tweaks to buildbot configuration

Pretty much sure more tweaks would be needed,
but need this to get started.

===================================================================

M	build_files/scons/tools/btools.py

===================================================================

diff --git a/build_files/scons/tools/btools.py b/build_files/scons/tools/btools.py
index 607b761..f7a5eb8 100644
--- a/build_files/scons/tools/btools.py
+++ b/build_files/scons/tools/btools.py
@@ -55,12 +55,12 @@ def get_version():
 
     raise Exception("%s: missing version string" % fname)
 
-def get_revision():
-    build_rev = os.popen('svnversion').read()[:-1] # remove \n
-    if build_rev == '' or build_rev==None:
-        build_rev = 'UNKNOWN'
+def get_hash():
+    build_hash = os.popen('git rev-parse --short HEAD').read().strip()
+    if build_hash == '' or build_hash == None:
+        build_hash = 'UNKNOWN'
 
-    return 'r' + build_rev
+    return build_hash
 
 
 # copied from: http://www.scons.org/wiki/AutoconfRecipes
@@ -80,7 +80,7 @@ def checkEndian():
 
 # This is used in creating the local config directories
 VERSION, VERSION_DISPLAY, VERSION_RELEASE_CYCLE = get_version()
-REVISION = get_revision()
+HASH = get_hash()
 ENDIAN = checkEndian()
 
 
@@ -693,7 +693,7 @@ def buildslave(target=None, source=None, env=None):
     branch = env['BUILDBOT_BRANCH']
 
     outdir = os.path.abspath(env['BF_INSTALLDIR'])
-    package_name = 'blender-' + VERSION+'-'+REVISION + '-' + platform
+    package_name = 'blender-' + VERSION+'-'+HASH + '-' + platform
     if branch != '':
         package_name = branch + '-' + package_name
     package_dir = os.path.normpath(outdir + os.sep + '..' + os.sep + package_name)




More information about the Bf-blender-cvs mailing list