chiark / gitweb /
Added the ability to flag an unbuildable release
authorCiaran Gultnieks <ciaran@ciarang.com>
Wed, 2 Mar 2011 21:47:48 +0000 (21:47 +0000)
committerCiaran Gultnieks <ciaran@ciarang.com>
Wed, 2 Mar 2011 21:47:48 +0000 (21:47 +0000)
README
build.py
update.py

diff --git a/README b/README
index 0cb51aa3643a97f93ea7427fa8b401d7d13d1213..4dc9f58531fcef60e214033d2e78c2ac77590070 100644 (file)
--- a/README
+++ b/README
@@ -120,6 +120,12 @@ The above specifies to build version 0.12, which has a version code of 3.
 The third parameter specifies the tag, commit or revision number from
 which to build it in the source repository.
 
+If the commit version starts with a !, that version is not built. Instead,
+everything after the ! is used as a reason why it can't be built. The
+purpose of this feature is to allow non-buildable releases (e.g. the source
+is not published) to be flagged, so the scripts don't generate repeated
+messages about them. (And also to record the information for review later).
+
 In addition to the three, always required, parameters described above,
 further parameters can be added (in name=value format) to apply further
 configuration to the build. These are:
index 16add9bfb2bfc96718ed92b837b8f07d258267d3..9adcad86c77c1fcf74ae6935e2dd6ca4aa5a7fcb 100755 (executable)
--- a/build.py
+++ b/build.py
@@ -76,9 +76,12 @@ for app in apps:
             dest_unsigned = dest + "_unsigned"
 
             if os.path.exists(dest):
-                print "Version " + thisbuild['version'] + " already exists"
+                print "..version " + thisbuild['version'] + " already exists"
+            elif thisbuild['commit'].startswith('!'):
+                print ("..skipping version " + thisbuild['version'] + " - " +
+                        thisbuild['commit'][1:])
             else:
-                print "Building version " + thisbuild['version']
+                print "..building version " + thisbuild['version']
 
                 if not got_source:
 
index f88c33b4cb3956af3de3345bd9d4d4b510a908be..d317e42a6e574d233b5709190e829bf6d24dca01 100755 (executable)
--- a/update.py
+++ b/update.py
@@ -337,6 +337,15 @@ for app in apps:
                                 + ") " + app['source'])
                         warnings += 1
 
+        # If we don't have the market version, check if there is a build
+        # with a commit ID starting with '!' - this means we can't build it
+        # for some reason, and don't want hassling about it...
+        if not gotmarketver and app['marketvercode'] != '0':
+            for build in app['builds']:
+                if build['vercode'] == app['marketvercode']:
+                    gotmarketver = True
+
+        # Output a message of harassment if we don't have the market version:
         if not gotmarketver and app['marketvercode'] != '0':
             if app['usebuilt']:
                 addr = app['source']