Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2014-12-23 08:04:03 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2014-12-23 08:04:03 +0300
commit9282d305bdc56522543129436db1e8a5d19cf39f (patch)
treeb6d0cdcc7dd3f4113cf9e4f9813c40f44d29746e /build_files/buildbot/master_unpack.py
parentde724a258eda45d1fed2b2176006c3b2df8abea2 (diff)
parent646a96bf8edc211a06f3df652101c265ee166e8d (diff)
Merge branch 'master' into texture_nodes_refactortexture_nodes_refactor
Conflicts: source/blender/nodes/texture/nodes/node_texture_math.c
Diffstat (limited to 'build_files/buildbot/master_unpack.py')
-rw-r--r--build_files/buildbot/master_unpack.py35
1 files changed, 18 insertions, 17 deletions
diff --git a/build_files/buildbot/master_unpack.py b/build_files/buildbot/master_unpack.py
index ecacf3bff6f..f7ed2d07d28 100644
--- a/build_files/buildbot/master_unpack.py
+++ b/build_files/buildbot/master_unpack.py
@@ -30,12 +30,12 @@ import zipfile
# extension stripping
def strip_extension(filename):
extensions = '.zip', '.tar', '.bz2', '.gz', '.tgz', '.tbz', '.exe'
- filename_noext, ext = os.path.splitext(filename)
- if ext in extensions:
- return strip_extension(filename_noext) # may have .tar.bz2
- else:
- return filename
+ for ext in extensions:
+ if filename.endswith(ext):
+ filename = filename[:-len(ext)]
+
+ return filename
# extract platform from package name
def get_platform(filename):
@@ -48,12 +48,11 @@ def get_platform(filename):
tokens = filename.split("-")
platforms = ('osx', 'mac', 'bsd',
'win', 'linux', 'source',
- 'solaris',
- 'mingw')
+ 'irix', 'solaris', 'mingw')
platform_tokens = []
found = False
- for token in tokens:
+ for i, token in enumerate(tokens):
if not found:
for platform in platforms:
if platform in token.lower():
@@ -65,20 +64,19 @@ def get_platform(filename):
return '-'.join(platform_tokens)
-
def get_branch(filename):
tokens = filename.split("-")
branch = ""
-
+
for token in tokens:
+ if token == "blender":
+ return branch
+
if branch == "":
branch = token
else:
branch = branch + "-" + token
- if token == "blender":
- return branch
-
return ""
# get filename
@@ -112,11 +110,16 @@ branch = get_branch(packagename)
if platform == '':
sys.stderr.write('Failed to detect platform ' +
- 'from package: %r\n' % packagename)
+ 'from package: %r\n' % packagename)
sys.exit(1)
# extract
-directory = 'public_html/download'
+if not branch or branch == 'master':
+ directory = 'public_html/download'
+elif branch == 'experimental-build':
+ directory = 'public_html/download/experimental'
+else:
+ directory = 'public_html/download'
try:
zf = z.open(package)
@@ -126,8 +129,6 @@ try:
zf.close()
z.close()
-
- os.remove(filename)
except Exception, ex:
sys.stderr.write('Failed to unzip package: %s\n' % str(ex))
sys.exit(1)