[Sugar-devel] bug with: "sugar-install-bundle to accept multiple files"

Simon Schampijer simon at schampijer.de
Thu Aug 25 07:41:13 EDT 2011


Hi,

The following bug stops olpc builds atm with the latest Sugar 0.93.2: 
http://dev.laptop.org/ticket/11178

The patch in question is:

commit ada284445e9a3ce96a0c9df4c299021254b0668d
Author: James Cameron <quozl at laptop.org>
Date:   Tue Mar 1 11:38:47 2011 +0000

     sugar-install-bundle to accept multiple files

     Signed-off-by: James Cameron <quozl at laptop.org>
     Acked-by: Sascha Silbe <silbe at activitycentral.com>

diff --git a/bin/sugar-install-bundle b/bin/sugar-install-bundle
index 52deada..a034135 100644
--- a/bin/sugar-install-bundle
+++ b/bin/sugar-install-bundle
@@ -1,5 +1,6 @@
  #!/usr/bin/env python
  import sys
+import fileinput

  from sugar.bundle.activitybundle import ActivityBundle

@@ -14,7 +15,8 @@ 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])
+for line in fileinput.input():
+    if line:
+        bundle = ActivityBundle(line)
+        bundle.install()
+        print "%s: '%s' installed." % (sys.argv[0], line)

If someone has a fix for it that is tested, I can look at it. Otherwise, 
I will revert it for now.

Regards,
    Simon


More information about the Sugar-devel mailing list