diff options
author | Ruben Rodriguez <ruben@activitycentral.com> | 2012-12-19 19:18:26 (GMT) |
---|---|---|
committer | Ruben Rodriguez <ruben@activitycentral.com> | 2012-12-19 19:18:26 (GMT) |
commit | 2b020d6c4efa8e209ca3b9aeeeb390bef413d834 (patch) | |
tree | 748dd889824650e47d268d4255fe00147244851f |
Initial release
-rw-r--r-- | 0001-383.patch | 33 | ||||
-rw-r--r-- | 0002-589.patch | 38 | ||||
-rw-r--r-- | 0003-825.patch | 33 | ||||
-rw-r--r-- | build.sh | 41 |
4 files changed, 145 insertions, 0 deletions
diff --git a/0001-383.patch b/0001-383.patch new file mode 100644 index 0000000..ad619c0 --- /dev/null +++ b/0001-383.patch @@ -0,0 +1,33 @@ +From cd8f002c5bccf9ba215b0d9a65d068ac56434762 Mon Sep 17 00:00:00 2001 +From: Ajay Garg <ajay@activitycentral.com> +Date: Thu, 22 Dec 2011 12:17:50 +0000 +Subject: [PATCH] sl#2822: Software-Update should pre-select only + to-be-upgraded activities by default. +Organization: Sugar Labs Foundation + +Only preselect the activities which are already installed on the +machine. We should not be selecting the 'new' activities by default. + + src/model.py | 1 + + 1 files changed, 1 insertions(+), 0 deletions(-) + +Signed-off-by: Anish Mangal <anish@activitycentral.com> +--- + src/model.py | 1 + + 1 files changed, 1 insertions(+), 0 deletions(-) + +diff --git a/src/model.py b/src/model.py +index 303f337..974c050 100755 +--- a/src/model.py ++++ b/src/model.py +@@ -449,6 +449,7 @@ class UpdateList(gtk.ListStore): + raise RuntimeError("can't find version for %s" % + row[UPDATE_URL]) + row[DESCRIPTION_BIG] = name ++ row[UPDATE_SELECTED] = False + row[DESCRIPTION_SMALL] = \ + _('New version %(version)s (Size: %(size)s)') % \ + {'version':version, 'size':_humanize_size(row[UPDATE_SIZE])} +-- +1.7.4.4 + diff --git a/0002-589.patch b/0002-589.patch new file mode 100644 index 0000000..4fd0b01 --- /dev/null +++ b/0002-589.patch @@ -0,0 +1,38 @@ +diff --git a/src/view.py b/src/view.py +index 11c9f78..e246a6a 100755 +--- a/src/view.py ++++ b/src/view.py +@@ -25,6 +25,7 @@ from sugar.graphics import style + + from jarabe.controlpanel.sectionview import SectionView + from jarabe.controlpanel.inlinealert import InlineAlert ++from jarabe.model import bundleregistry + + import model + from model import _humanize_size, _svg2pixbuf, inhibit_suspend +@@ -498,6 +499,9 @@ class ActivityUpdater(SectionView): + + def __init__(self, modelwrapper, alerts): + SectionView.__init__(self) ++ ++ bundleregistry.get_registry().disable_directory_monitoring() ++ + self._in_sugar = (modelwrapper is not None) + self.set_spacing(style.DEFAULT_SPACING) + self.set_border_width(style.DEFAULT_SPACING * 2) +@@ -657,6 +661,12 @@ class ActivityUpdater(SectionView): + def destroy(self, widget, data=None): + gtk.main_quit() + ++ def perform_cancel_actions(self): ++ bundleregistry.get_registry().enable_directory_monitoring() ++ ++ def perform_accept_actions(self): ++ bundleregistry.get_registry().enable_directory_monitoring() ++ + def main(self): + """Start gtk main loop.""" + gtk.main() +-- +1.7.4.4 + diff --git a/0003-825.patch b/0003-825.patch new file mode 100644 index 0000000..aa9f46e --- /dev/null +++ b/0003-825.patch @@ -0,0 +1,33 @@ +From 25be6bf09a52249332424c325d335e66f21bdd68 Mon Sep 17 00:00:00 2001 +From: Ajay Garg <ajay@activitycentral.com> +Date: Thu, 15 Mar 2012 12:02:14 +0530 +Subject: [olpc-updater PATCH] au#825: Check for a existence for an already + existing "library" bundle; else the + corresponding "activity" will be + continued to be shown as new in + "Software-Update". +Organization: Sugar Labs Foundation +Signed-off-by: Ajay Garg <ajay@activitycentral.com> +--- + src/model.py | 6 +++++- + 1 files changed, 5 insertions(+), 1 deletions(-) + +diff --git a/src/model.py b/src/model.py +index 974c050..60195c7 100755 +--- a/src/model.py ++++ b/src/model.py +@@ -413,7 +413,11 @@ class UpdateList(gtk.ListStore): + zf.getinfo('%s/activity/activity.info' % activity_base) + is_activity = True + except KeyError: +- is_activity = False ++ try: ++ zf.getinfo('%s/library/library.info' % activity_base) ++ is_activity = False ++ except: ++ raise RuntimeError ("not activity or library") + if is_activity: + cp = actutils.activity_info_from_zipfile(zf) + SECTION = 'Activity' +-- +1.7.4.4 diff --git a/build.sh b/build.sh new file mode 100644 index 0000000..d4ce7aa --- /dev/null +++ b/build.sh @@ -0,0 +1,41 @@ +#!/bin/bash + +set -ex + +rm -rf src +git clone git://git.sugarlabs.org/sugar-update-control/mainline.git src + +# Prepare spec +sed '/Version:/ s/$/\nEpoch: 1/' -i src/sugar-update-control.spec +sed '/Release:/ s/%/.dx%/' -i src/sugar-update-control.spec +sed "1s/$/\n%define _default_patch_fuzz 20/" -i src/sugar-update-control.spec +rm src/.git* -rf +n=1 +for i in *.patch +do +sed "/Source0/ s/$/\nPatch$n: $i/" -i src/sugar-update-control.spec +sed "/%setup/ s/$/\n%patch$n -p1 -b .$i/" -i src/sugar-update-control.spec +let n++ +done + +# Place for compiling +version=$(grep Version src/sugar-update-control.spec |sed 's/.* //') +mv src sugar-update-control-$version +tar -zcvf sugar-update-control-$version.tar.gz sugar-update-control-$version +mv sugar-update-control-$version.tar.gz /root/rpmbuild/SOURCES +cp *.patch /root/rpmbuild/SOURCES +mv sugar-update-control-$version/sugar-update-control.spec /root/rpmbuild/SPECS +rm sugar-update-control-$version -rf + +# Clean and compile +rm /root/rpmbuild/SRPMS/sugar-update-control* +rm /root/rpmbuild/RPMS/noarch/sugar-update-control* +rpmbuild -ba /root/rpmbuild/SPECS/sugar-update-control.spec 2>&1 |tee buildlog + +# Copy results +rm -rf output-$version +mkdir output-$version +cp /root/rpmbuild/SRPMS/sugar-update-control* output-$version/ +cp /root/rpmbuild/RPMS/noarch/sugar-update-control* output-$version/ +cp /root/rpmbuild/SPECS/sugar-update-control.spec output-$version/ +mv buildlog output-$version/ |