Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Schampijer <simon@schampijer.de>2009-06-19 09:10:38 (GMT)
committer Simon Schampijer <simon@schampijer.de>2009-06-19 09:10:38 (GMT)
commit2d1057e6d8e74aecfa82c0b8e51a2c8d772a7923 (patch)
treede8a2ed8ab89ce2ead5e37cb48de8adde11b1934
parent9a63eca08219d0905036a0163ba733ca5b0710ea (diff)
Script to install activities (with mime type)
-rwxr-xr-xinstall-activity.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/install-activity.py b/install-activity.py
new file mode 100755
index 0000000..26f0269
--- /dev/null
+++ b/install-activity.py
@@ -0,0 +1,17 @@
+#!/usr/bin/env python
+import sys
+
+from sugar.bundle.activitybundle import ActivityBundle
+
+def cmd_help():
+ print 'Usage: sugar-install-bundle [ bundlename ] \n\n\
+ Install an activity bundle (.xo). \n'
+
+if len(sys.argv) != 2:
+ cmd_help()
+ sys.exit(2)
+
+bundle = ActivityBundle(sys.argv[1])
+bundle.install()
+
+print "%s: '%s' installed." % (sys.argv[0], sys.argv[1])