summaryrefslogtreecommitdiffstats
path: root/bin/update
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@googlemail.com>2016-08-28 16:04:35 +0200
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2017-05-19 03:43:20 +0200
commit1bff19a2c0de2825bec287ffd64bee6bace3f448 (patch)
treeaa152ef5273100f78a776318ee537b689d2adbc4 /bin/update
parentadd configure setting for the update channel (diff)
downloadcore-1bff19a2c0de2825bec287ffd64bee6bace3f448.tar.gz
core-1bff19a2c0de2825bec287ffd64bee6bace3f448.zip
add makefile part to generate mar file and update info
We still need some parts for the partial update files but we already generate the build information and the complete mar file. Change-Id: I2ae0de0b83518bc3093848b66b6f3054ebd388e1
Diffstat (limited to 'bin/update')
-rwxr-xr-xbin/update/create_build_config.py21
1 files changed, 21 insertions, 0 deletions
diff --git a/bin/update/create_build_config.py b/bin/update/create_build_config.py
new file mode 100755
index 000000000000..964c92256fb7
--- /dev/null
+++ b/bin/update/create_build_config.py
@@ -0,0 +1,21 @@
+#! /usr/bin/env python3
+
+import json
+import sys
+import os
+
+def main(argv):
+ if len(argv) < 6:
+ print("Usage: create_build_config.py $PRODUCTNAME $VERSION $BUILDID $UPDATECHANNEL $TARGETDIR")
+
+ data = { 'productName' : argv[1],
+ 'version' : argv[2],
+ 'buildNumber' : argv[3],
+ 'updateChannel' : argv[4]
+ }
+
+ with open(os.path.join(argv[5], "build_config.json"), "w") as f:
+ json.dump(data, f, indent=4)
+
+if __name__ == "__main__":
+ main(sys.argv)