Re: Journal integration for Scratch

2009-01-13 Thread Bert Freudenberg
On 13.01.2009, at 06:55, Philipp Kocher wrote:

 Thanks Tomeu to lead me to the /home/olpc/.local directory. However,  
 the
 mimetypes.xml is not necessary to get the icon in the journal. I just
 had to copy the scratch icon file in the activity directory to
 application-x-scratch-project.svg (also in the scratch activity
 dirctory). The Memorize Activity is a good example for using that  
 feature.
 Sugar has to be restarted after installing Scratch to show the icon.

Thanks! This is not documented anywhere I know of. So I put it here:

http://wiki.laptop.org/go/Activity_bundles#Bundle_Structure

Hope someone can proof-read / confirm.

 Etoys gets configured by different packages. e.g. the rpm
 etoys-3.0.2153-1.noarch is adding the file
 /usr/share/mime/packges/etoys.xml and the rpm sugar- 
 artwork-0.82.3-1.olpc3 is
 adding the file
 /usr/share/icons/sugar/scalable/mimetypes/application-x-squake- 
 project.svg.


Interesting ... thanks for the archaeology :)

Eben: see, I did remember correctly there was an icon for the document  
independent of the activity ;)

That must be the smaller version.

- Bert -


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Journal integration for Scratch

2009-01-13 Thread Tomeu Vizoso
On Tue, Jan 13, 2009 at 06:55, Philipp Kocher philipp.koc...@gmx.net wrote:


 Tomeu Vizoso wrote:

 On Mon, Jan 12, 2009 at 18:50, Bert Freudenberg b...@freudenbergs.de
 wrote:

 On 12.01.2009, at 18:11, Tomeu Vizoso wrote:

 So what would the Scratch activity have to do so files put into the
 Journal
 (maybe by downloading) are displayed using a Scratch icon rather than
 the
 generic document icon?

 Shipping a mimetypes.xml file inside the bundle as explained here:

 http://wiki.laptop.org/go/Activity_bundles#Bundle_Structure

 Sugar will call update-mime-database and will merge that file into the
 xdg mime database.

 I think that John is already trying this.

 Guess I'm confused then - I thought that's exactly what Philipp had done.

 I think he just changed the mime_types field in the .info file.

 And I just checked and it does work with Etoys projects. When downloading
 one it indeed gets an etoys icon (although at a smaller size - why is
 that?)

 No idea, though I think that the mime database is updated in the etoys
 rpm and not in the bundle, am I right?

 Regards,

 Tomeu


 Thanks Tomeu to lead me to the /home/olpc/.local directory. However, the
 mimetypes.xml is not necessary to get the icon in the journal. I just
 had to copy the scratch icon file in the activity directory to
 application-x-scratch-project.svg (also in the scratch activity
 dirctory). The Memorize Activity is a good example for using that feature.
 Sugar has to be restarted after installing Scratch to show the icon.

Yes, you are right in that you don't need to mess with mimetypes.xml
if you only want to set the icon for a mime type.

mimetype.xml also serves to associate a file extension with a mime
type, and Scratch might also want this so that scratch projects copied
from a removable files are correctly identified as such.

Thanks,

Tomeu

 John, could you please make the following changes in the next Scratch
 version:
 - add the line mime_types = application/x-scratch-project to the
 activity.info file
 - copy the scratch icon to application-x-scratch-project.svg in the
 activity directory

 Etoys gets configured by different packages. e.g. the rpm
 etoys-3.0.2153-1.noarch is adding the file
 /usr/share/mime/packges/etoys.xml and the rpm sugar-artwork-0.82.3-1.olpc3
 is
 adding the file
 /usr/share/icons/sugar/scalable/mimetypes/application-x-squake-project.svg.

 Regards,
 Philipp


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


OLPC and Catalyst invitation to meet Walter Bender - sugarlabs founder

2009-01-13 Thread Tabitha Roder
Hello New Zealand OLPC volunteers and friends

OLPC Wellington http://wiki.laptop.org/go/Projects/WellyNZTesters
and Catalyst
IT Ltd http://www.catalyst.net.nz/ invite you to meet Walter Bender,
founder of sugarlabs http://sugarlabs.org/, a non-profit foundation.
Python based, Sugar enhances educational experience by emphasising
collaboration and expression. Sugar is the interface used on XOs distributed
around the world by OLPC.

Venue - Catalyst House http://www.catalyst.net.nz/contact, 150 Willis
Street, Wellington.

RSVP session 12-2 or 5-7 on 27 January by emailing tabi...@learning.ac.nz

Looking forward to seeing you there.

Tabitha Roder
(64)21482229

Support OLPC G1G1 - laptop.org/xo
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: HTML-based/Browser apps (was Re: anti-cheating)

2009-01-13 Thread S Page
Carlos Nazareno wrote:

 You can go with Processing (http://www.processing.org/) but Java is a
 bit problematic on the XO.

Heh, http://ejohn.org/blog/processingjs/ is the Processing language 
running in a canvas.  Works on XO, slowly.  (I hope XULRunner 1.9.1 
with the Tracemonkey JIT shows up in joyrunner builds.)

 Why put yourself through unnecessary pain with the
 HTML5/Javascript/CSS/SVG/whathaveyouforaudiovideowebcam combo? Add
 to that the added headache of the standards fragmented browser
 landscape.

There is no fragmentation, the XO ships with XULRunner.

 Flash gets the job done, and gets it done easy.

I worked at Macromedia for 9 years, I know well of Flash's many 
benefits, and many downsides for OLPC.  Rather than debate it, if 
there's Flash content relevant to OLPC's mission, mention it on the 
wiki.  A few days ago I added a brief mention of the SWF format to 
http://wiki.laptop.org/go/Image_file_formats before I noticed someone 
had already put it under List of objectionable formats on the talk 
page; I don't care deeply either way.

--
=S Page
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Journal integration for Scratch

2009-01-13 Thread John Maloney
Hi, Phillip.

Thanks for all your hard work in tracking this down. I had looked at  
several other packages, including EToys, and couldn't figure out from  
them how to do this.

I will make these changes to the next XO Scratch bundle.

Is that all I need to do? What about the mime types XML file similar  
to the one added by Etoys? Does that turn out to be unnecessary?

-- John


On Jan 13, 2009, at 12:55 AM, Philipp Kocher wrote:
 Tomeu Vizoso wrote:
 On Mon, Jan 12, 2009 at 18:50, Bert Freudenberg  
 b...@freudenbergs.de wrote:
 On 12.01.2009, at 18:11, Tomeu Vizoso wrote:
 So what would the Scratch activity have to do so files put into  
 the
 Journal
 (maybe by downloading) are displayed using a Scratch icon rather  
 than the
 generic document icon?
 Shipping a mimetypes.xml file inside the bundle as explained here:

 http://wiki.laptop.org/go/Activity_bundles#Bundle_Structure

 Sugar will call update-mime-database and will merge that file  
 into the
 xdg mime database.

 I think that John is already trying this.

 Guess I'm confused then - I thought that's exactly what Philipp  
 had done.
 I think he just changed the mime_types field in the .info file.
 And I just checked and it does work with Etoys projects. When  
 downloading
 one it indeed gets an etoys icon (although at a smaller size - why  
 is that?)
 No idea, though I think that the mime database is updated in the  
 etoys
 rpm and not in the bundle, am I right?
 Regards,
 Tomeu

 Thanks Tomeu to lead me to the /home/olpc/.local directory. However,  
 the
 mimetypes.xml is not necessary to get the icon in the journal. I just
 had to copy the scratch icon file in the activity directory to
 application-x-scratch-project.svg (also in the scratch activity
 dirctory). The Memorize Activity is a good example for using that  
 feature.
 Sugar has to be restarted after installing Scratch to show the icon.

 John, could you please make the following changes in the next Scratch
 version:
 - add the line mime_types = application/x-scratch-project to the
 activity.info file
 - copy the scratch icon to application-x-scratch-project.svg in the
 activity directory

 Etoys gets configured by different packages. e.g. the rpm
 etoys-3.0.2153-1.noarch is adding the file
 /usr/share/mime/packges/etoys.xml and the rpm sugar- 
 artwork-0.82.3-1.olpc3 is
 adding the file
 /usr/share/icons/sugar/scalable/mimetypes/application-x-squake- 
 project.svg.

 Regards,
 Philipp


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Journal integration for Scratch

2009-01-13 Thread Bert Freudenberg

On 13.01.2009, at 13:30, John Maloney wrote:

 Hi, Phillip.

 Thanks for all your hard work in tracking this down. I had looked at  
 several other packages, including EToys, and couldn't figure out  
 from them how to do this.

 I will make these changes to the next XO Scratch bundle.

 Is that all I need to do? What about the mime types XML file similar  
 to the one added by Etoys? Does that turn out to be unnecessary?

That file provides the mapping from file extensions to MIME types, so  
it is needed for Scratch bundles downloaded from the Web or a USB  
memory stick to be recognized as such.

- Bert -


   -- John


 On Jan 13, 2009, at 12:55 AM, Philipp Kocher wrote:
 Tomeu Vizoso wrote:
 On Mon, Jan 12, 2009 at 18:50, Bert Freudenberg b...@freudenbergs.de 
  wrote:
 On 12.01.2009, at 18:11, Tomeu Vizoso wrote:
 So what would the Scratch activity have to do so files put into  
 the
 Journal
 (maybe by downloading) are displayed using a Scratch icon  
 rather than the
 generic document icon?
 Shipping a mimetypes.xml file inside the bundle as explained here:

 http://wiki.laptop.org/go/Activity_bundles#Bundle_Structure

 Sugar will call update-mime-database and will merge that file  
 into the
 xdg mime database.

 I think that John is already trying this.

 Guess I'm confused then - I thought that's exactly what Philipp  
 had done.
 I think he just changed the mime_types field in the .info file.
 And I just checked and it does work with Etoys projects. When  
 downloading
 one it indeed gets an etoys icon (although at a smaller size -  
 why is that?)
 No idea, though I think that the mime database is updated in the  
 etoys
 rpm and not in the bundle, am I right?
 Regards,
 Tomeu

 Thanks Tomeu to lead me to the /home/olpc/.local directory.  
 However, the
 mimetypes.xml is not necessary to get the icon in the journal. I just
 had to copy the scratch icon file in the activity directory to
 application-x-scratch-project.svg (also in the scratch activity
 dirctory). The Memorize Activity is a good example for using that  
 feature.
 Sugar has to be restarted after installing Scratch to show the icon.

 John, could you please make the following changes in the next Scratch
 version:
 - add the line mime_types = application/x-scratch-project to the
 activity.info file
 - copy the scratch icon to application-x-scratch-project.svg in the
 activity directory

 Etoys gets configured by different packages. e.g. the rpm
 etoys-3.0.2153-1.noarch is adding the file
 /usr/share/mime/packges/etoys.xml and the rpm sugar- 
 artwork-0.82.3-1.olpc3 is
 adding the file
 /usr/share/icons/sugar/scalable/mimetypes/application-x-squake- 
 project.svg.

 Regards,
 Philipp





___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Sugar-devel] Journal integration for Scratch

2009-01-13 Thread Eben Eliason
On Tue, Jan 13, 2009 at 3:54 AM, Bert Freudenberg b...@freudenbergs.de wrote:
 On 13.01.2009, at 06:55, Philipp Kocher wrote:

 Thanks Tomeu to lead me to the /home/olpc/.local directory. However,
 the
 mimetypes.xml is not necessary to get the icon in the journal. I just
 had to copy the scratch icon file in the activity directory to
 application-x-scratch-project.svg (also in the scratch activity
 dirctory). The Memorize Activity is a good example for using that
 feature.
 Sugar has to be restarted after installing Scratch to show the icon.

 Thanks! This is not documented anywhere I know of. So I put it here:

 http://wiki.laptop.org/go/Activity_bundles#Bundle_Structure

 Hope someone can proof-read / confirm.

 Etoys gets configured by different packages. e.g. the rpm
 etoys-3.0.2153-1.noarch is adding the file
 /usr/share/mime/packges/etoys.xml and the rpm sugar-
 artwork-0.82.3-1.olpc3 is
 adding the file
 /usr/share/icons/sugar/scalable/mimetypes/application-x-squake-
 project.svg.


 Interesting ... thanks for the archaeology :)

 Eben: see, I did remember correctly there was an icon for the document
 independent of the activity ;)

Indeed. However, that one's not mine, and I wasn't aware of it. I
think it must have been copied before I or someone else (don't recall)
matched the Etoys icon to the spec.  I just checked the file you
mention, and it clearly has a 75x75 pixel canvas, which is why it's
being scaled down.

- Eben

 That must be the smaller version.

 - Bert -


 ___
 Sugar-devel mailing list
 sugar-de...@lists.sugarlabs.org
 http://lists.sugarlabs.org/listinfo/sugar-devel

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


XOCamp 2: Day 2 update

2009-01-13 Thread Samuel Klein
We've made a few schedule changes today, with talks about
customization, signing, and activation moved to later in the
afternoon, and a longer session on the school server through the
morning.

http://blog.laptop.org/2009/01/12/xo-camp-on-tv/

Feel free to leave comments, questions and ideas on the schedule's
talkpage if you can't join in person.

SJ
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Sugar-devel] Journal integration for Scratch

2009-01-13 Thread Bert Freudenberg

On 13.01.2009, at 17:22, Eben Eliason wrote:

 /usr/share/icons/sugar/scalable/mimetypes/application-x-squake-
 project.svg.

 Interesting ... thanks for the archaeology :)

 Eben: see, I did remember correctly there was an icon for the  
 document
 independent of the activity ;)

 Indeed. However, that one's not mine, and I wasn't aware of it. I
 think it must have been copied before I or someone else (don't recall)
 matched the Etoys icon to the spec.  I just checked the file you
 mention, and it clearly has a 75x75 pixel canvas, which is why it's
 being scaled down.


I see. So this is really really old, from before the icon dimensions  
were changed. Someone who understood the system back then must have  
taken the Etoys icon and checked it in as the mime type icon. Would  
make sense to upgrade it to the current icon now :)

- Bert -

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Sugar-devel] Journal integration for Scratch

2009-01-13 Thread Eben Eliason
On Tue, Jan 13, 2009 at 12:49 PM, Bert Freudenberg b...@freudenbergs.de wrote:

 On 13.01.2009, at 17:22, Eben Eliason wrote:

 /usr/share/icons/sugar/scalable/mimetypes/application-x-squake-
 project.svg.

 Interesting ... thanks for the archaeology :)

 Eben: see, I did remember correctly there was an icon for the
 document
 independent of the activity ;)

 Indeed. However, that one's not mine, and I wasn't aware of it. I
 think it must have been copied before I or someone else (don't recall)
 matched the Etoys icon to the spec.  I just checked the file you
 mention, and it clearly has a 75x75 pixel canvas, which is why it's
 being scaled down.


 I see. So this is really really old, from before the icon dimensions
 were changed. Someone who understood the system back then must have
 taken the Etoys icon and checked it in as the mime type icon. Would
 make sense to upgrade it to the current icon now :)

Right. From my understanding of the conversation, this needs to be
updated within the bundle, right?  This isn't something that should
need to live in artwork.

- Eben


 - Bert -

 ___
 Sugar-devel mailing list
 sugar-de...@lists.sugarlabs.org
 http://lists.sugarlabs.org/listinfo/sugar-devel

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: [Sugar-devel] Journal integration for Scratch

2009-01-13 Thread Bert Freudenberg

On 13.01.2009, at 19:14, Eben Eliason wrote:

 On Tue, Jan 13, 2009 at 12:49 PM, Bert Freudenberg b...@freudenbergs.de 
  wrote:

 On 13.01.2009, at 17:22, Eben Eliason wrote:

 /usr/share/icons/sugar/scalable/mimetypes/application-x-squake-
 project.svg.

 Interesting ... thanks for the archaeology :)

 Eben: see, I did remember correctly there was an icon for the
 document
 independent of the activity ;)

 Indeed. However, that one's not mine, and I wasn't aware of it. I
 think it must have been copied before I or someone else (don't  
 recall)
 matched the Etoys icon to the spec.  I just checked the file you
 mention, and it clearly has a 75x75 pixel canvas, which is why it's
 being scaled down.


 I see. So this is really really old, from before the icon dimensions
 were changed. Someone who understood the system back then must have
 taken the Etoys icon and checked it in as the mime type icon. Would
 make sense to upgrade it to the current icon now :)

 Right. From my understanding of the conversation, this needs to be
 updated within the bundle, right?  This isn't something that should
 need to live in artwork.


What's the precedence of icons in the system vs the bundle?

- Bert -


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


bounce moved to gitorious at SL

2009-01-13 Thread Rafael Enrique Ortiz Guerrero
Hello

I've followed the instructions on
http://sugarlabs.org/go/ActivityTeam/How_to_migrate_from_OLPC

to have bounce on gitorious.

http://git.sugarlabs.org/projects/bounce


cheers!.
Rafael Ortiz
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Activities migration status

2009-01-13 Thread Wade Brainerd
Awesome, thank you Rafael!

Today I went through dev.laptop.org/git identifying those projects
that contain Sugar activities.

http://sugarlabs.org/go/ActivityTeam/ActivityStatus

Still remaining is to go through Activities/All (and code.google.com,
personal sites, etc) and find those activities which do not have d.l.o
repositories.

The list is *massive*.  I had no idea we had so many cool activities
in various stages of development!  The process of finding their
authors and migrating them to SL will result in some great new
software for Sugar.  It will be a lot of work but I know the end
result will be worth it.

Best regards,
Wade

On Tue, Jan 13, 2009 at 9:05 PM, Rafael Enrique Ortiz Guerrero
dir...@gmail.com wrote:
 Hello

 I've followed the instructions on
 http://sugarlabs.org/go/ActivityTeam/How_to_migrate_from_OLPC

 to have bounce on gitorious.

 http://git.sugarlabs.org/projects/bounce


 cheers!.
 Rafael Ortiz

 ___
 Sugar-devel mailing list
 sugar-de...@lists.sugarlabs.org
 http://lists.sugarlabs.org/listinfo/sugar-devel


___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Activities migration status

2009-01-13 Thread Rafael Enrique Ortiz Guerrero
Hi Wade

Thanks to you..there are too many people excited about the activity team.

i'll keep helping :). the work is indeed massive!


Rafael Ortiz


On Tue, Jan 13, 2009 at 11:10 PM, Wade Brainerd wad...@gmail.com wrote:

 Awesome, thank you Rafael!

 Today I went through dev.laptop.org/git identifying those projects
 that contain Sugar activities.

 http://sugarlabs.org/go/ActivityTeam/ActivityStatus

 Still remaining is to go through Activities/All (and code.google.com,
 personal sites, etc) and find those activities which do not have d.l.o
 repositories.

 The list is *massive*.  I had no idea we had so many cool activities
 in various stages of development!  The process of finding their
 authors and migrating them to SL will result in some great new
 software for Sugar.  It will be a lot of work but I know the end
 result will be worth it.

 Best regards,
 Wade

 On Tue, Jan 13, 2009 at 9:05 PM, Rafael Enrique Ortiz Guerrero
 dir...@gmail.com wrote:
  Hello
 
  I've followed the instructions on
  http://sugarlabs.org/go/ActivityTeam/How_to_migrate_from_OLPC
 
  to have bounce on gitorious.
 
  http://git.sugarlabs.org/projects/bounce
 
 
  cheers!.
  Rafael Ortiz
 
  ___
  Sugar-devel mailing list
  sugar-de...@lists.sugarlabs.org
  http://lists.sugarlabs.org/listinfo/sugar-devel
 
 

___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: Journal integration for Scratch

2009-01-13 Thread Philipp Kocher

Hi John

Yes, we need the mimetypes.xml file as well (thanks Tomeu I forgot the 
USB flash drive use case). I have tested the attached mimetypes.xml. It 
is working fine. Put it in the activity directory.


Furthermore we have to change the scratch-activity script, so the 
parameter with the scratch project object-id gets converted 
(copy-from-journal) in a file and passed on to scratch. See the attached 
scratch-activity script. I am not an expert with bash scripts, so please 
give feedback.


I would like to extend the script so project files in the journal 
directory are copied back to the journal after exiting scratch, but for 
opening project it should work fine.


Best regards,
Philipp

John Maloney wrote:

Hi, Phillip.

Thanks for all your hard work in tracking this down. I had looked at 
several other packages, including EToys, and couldn't figure out from 
them how to do this.


I will make these changes to the next XO Scratch bundle.

Is that all I need to do? What about the mime types XML file similar to 
the one added by Etoys? Does that turn out to be unnecessary?


-- John


On Jan 13, 2009, at 12:55 AM, Philipp Kocher wrote:

Tomeu Vizoso wrote:
On Mon, Jan 12, 2009 at 18:50, Bert Freudenberg 
b...@freudenbergs.de wrote:

On 12.01.2009, at 18:11, Tomeu Vizoso wrote:

So what would the Scratch activity have to do so files put into the
Journal
(maybe by downloading) are displayed using a Scratch icon rather 
than the

generic document icon?

Shipping a mimetypes.xml file inside the bundle as explained here:

http://wiki.laptop.org/go/Activity_bundles#Bundle_Structure

Sugar will call update-mime-database and will merge that file into the
xdg mime database.

I think that John is already trying this.


Guess I'm confused then - I thought that's exactly what Philipp had 
done.

I think he just changed the mime_types field in the .info file.
And I just checked and it does work with Etoys projects. When 
downloading
one it indeed gets an etoys icon (although at a smaller size - why 
is that?)

No idea, though I think that the mime database is updated in the etoys
rpm and not in the bundle, am I right?
Regards,
Tomeu


Thanks Tomeu to lead me to the /home/olpc/.local directory. However, the
mimetypes.xml is not necessary to get the icon in the journal. I just
had to copy the scratch icon file in the activity directory to
application-x-scratch-project.svg (also in the scratch activity
dirctory). The Memorize Activity is a good example for using that 
feature.

Sugar has to be restarted after installing Scratch to show the icon.

John, could you please make the following changes in the next Scratch
version:
- add the line mime_types = application/x-scratch-project to the
activity.info file
- copy the scratch icon to application-x-scratch-project.svg in the
activity directory

Etoys gets configured by different packages. e.g. the rpm
etoys-3.0.2153-1.noarch is adding the file
/usr/share/mime/packges/etoys.xml and the rpm 
sugar-artwork-0.82.3-1.olpc3 is

adding the file
/usr/share/icons/sugar/scalable/mimetypes/application-x-squake-project.svg. 



Regards,
Philipp



?xml version=1.0 encoding=UTF-8?
mime-info xmlns=http://www.freedesktop.org/standards/shared-mime-info;
   mime-type type=application/x-scratch-project
 commentScratch Project/comment
 glob pattern=*.sb/
   /mime-type
/mime-info
#!/bin/sh
# Author: Bert Freudenberg
# Modified by: John Maloney
# Purpose: Run Scratch using the Squeak virtual machine

echo scratch-activity
echo $@

echo $0 $@
echo

# arguments are unordered, have to loop
args=
while [ -n $2 ] ; do
case $1 in
-b | --bundle-id)   bundle_id=$2   ; args=$args BUNDLE_ID $2 ;;
-a | --activity-id) activity_id=$2 ; args=$args ACTIVITY_ID $2;;
-o | --object-id)   object_id=$2   ; args=$args OBJECT_ID $2;;
-u | --uri) uri=$2 ; args=$args URI $2;;
*) echo unknown argument $1 $2 ;;
esac
shift;shift
done

# really need bundle id and activity id
if [ -z $bundle_id -o -z $activity_id ] ; then
  echo ERROR: bundle-id and activity-id arguments required
  echo Aborting
  exit 1
fi

# some debug output
echo launching $bundle_id instance $activity_id
[ -n $object_id ]  echo with journal obj $object_id
[ -n $uri   ]  echo loading uri $uri
echo

# do not crash on dbus errors
export DBUS_FATAL_WARNINGS=0

if [ -n $object_id ] ; then
JOURNAL_DIR=$SUGAR_ACTIVITY_ROOT/data/Journal
mkdir -p $JOURNAL_DIR
temp_filename=$JOURNAL_DIR/temp.sb
title=`copy-from-journal -o $object_id -m $temp_filename | grep 
title `
# title is something like this for files downloaded from server:
#   title - File do_math_3.sb from 
http://schoolserver/Scratch/do_math_3.sb.
# or like this if copied from USB flash drive:
#   title - do_math_3
title=${title#*title - } #cut off description
echo title: $title

# workaround for copy-from-journal bug 

Activity not getting registered in the journal

2009-01-13 Thread shivaprasad javali
Hi,

  I have an activity written in c++. I have used catmoran's libsugarise
library to sugarise my activity and create the activity bundle. It runs fine
on the XO but when I run my activity it is not registered in the journal. I
have attached a copy of my activity.info file and sugarise script which
loads the libsugarise and calls my application. Can anyone figure out why
the activity is not registered in the journal?

  Also I wanted to ask one more thing. The applciation needs the home
path i.e. path to /home/olpc. But I cannot get this from the $HOME variable
as this will not be where the activity is installed when run from the
activity launcher. So I have hardcoded the path in my application to
/home/olpc. How safe do you think it is. Is it reasonable to assume that the
users home path will be this. Is there any other way I can get this path?

Thanks
jbsp72


activity.info
Description: Binary data


sugarize
Description: Binary data
___
Devel mailing list
Devel@lists.laptop.org
http://lists.laptop.org/listinfo/devel


Re: What keeps me going...

2009-01-13 Thread Ankur Verma
+1!

Very well written with highly inspirational thoughts.

--
Ankur

On Tue, Jan 13, 2009 at 3:28 AM, Sameer Verma sve...@sfsu.edu wrote:

 So, a lot of people have been asking me this lately in the OLPC
 context. What keeps you going? Of course, this question has been
 asked by different people with different intentions. Some are
 genuinely surprised that I have so much free time, while others
 suspect a hidden treasure. So, I decided to shoot off this e-mail to
 the lists for two reasons. One, I am not sure which list is
 appropriate, and two, I think many of us do question the merits of
 this project from time to time, and I want to share my sentiments with
 you all. Feel free to delete if you don't like it.

 During my visit to India a long time friend asked me this question.
 What keeps you going with a project like this? He wanted to know
 where I got all this free time from. Well, the assumption is a bit
 off. A lot of the time I put into the project aligns with my
 profession as well. Sustainable IT, network infrastructure, software
 development, collaboration, etc. are all parts of my research stream.
 so is FOSS development, adoption and use. So, finding time isn't that
 much of a stretch. Its a two way street. I am able to bring these
 things into my classroom and into my research. Of course, without
 support from my family, this would be extremely difficult. For
 instance, when I am off, gallivanting in Jamaica and working on a
 pilot there, my wife has to cover for me and she does so with a lot of
 effort, but we think its all for a good cause. We hope some of this
 will make a difference in the lives of communities there.

 Others, such as some of my students, have asked me the same question
 but with a little wink wink glint in their eye. They think there is
 something ulterior or somehow I am getting paid or I am bucking the
 system (wonder where they got that idea from). Getting across the
 volunteer ethic is very hard. Either you get it or you don't. Of
 course, volunteer-ism is driven by many things including ego, fame,
 and little green laptops. It is also driven by a desire to make a
 difference in the system. Sometimes the system doesn't want that
 change, but we still push for it. But that's another e-mail.

 Then there are some of us who have an addictive desire to take things
 apart. You know who I'm taking about! Take apart and put back together
 things that most people would leave untouched. People who subscribe to
 Make magazine or own a soldering iron would know. Its a strange itch,
 but its an ethic that brings people together. Its hard to explain
 these things to people who've never opened a radio, or a watch. On the
 other hand, if you are the Maker type, you would instantly know. We
 were surprised at the courage of attendees at the December OLPC-SF
 meeting. They took their XOs apart and put them back together. Well,
 most of us did. Only Robert needed some help from a 7 year old
 attendee :-) (Sorry Robert. Couldn't resist!)

 I think its a lot of these reasons that keep us all together in this
 project and its offshoots, but one experience has captured my
 enthusiasm unlike any other. This was a trip to Khairat, India's first
 pilot site (http://wiki.laptop.org/go/Khairat_school). I had seen
 pictures, and even videos and news clips of Khairat. But driving out
 there with the folks from Reliance (the pilot partner) was a turning
 point. Seeing five year olds handling their XOs with ease was just
 amazing. Seeing them document their lives and showing me photos via
 the journal suddenly made a lot of sense. All discussions of a lack of
 a file manager were moot at that point. Rahul and Manisha sure don't
 need a file manager to show me what they did! They could care less
 about /etc or /usr/local/  I wish I could get the journal on my Ubuntu
 Thinkpad laptop.

 They had documented a tight rope walker who visited Khairat. They had
 documented Gandhi's birthday (2nd Oct) and showed me the photos. They
 didn't care that Sugar was slow. After all, for them to know that
 Sugar is slow, they would have to know something faster! They love
 their XOs and it shows. Then there is Mr. Surve, the teacher at
 Khairat. With very little training, this man gets his gang going. He's
 built solar system animations in e-toys and precipitation cycle in
 Paint. He has made his own lesson plans in Write and is constantly
 yelling in Marathi (local language) Go to the neighborhood. Join the
 mesh. Who woulda thunk it? In the middle-of-nowhere-Khairat, a
 teacher is yelling a his kids to join the mesh. A draft version of
 802.11s has made it that far! Of course Rahul and Manisha don't know
 that. And they don't need to, because we have a team of do-gooders who
 take care of all that. And that's where my respect and unconditional
 support for this group comes from. I've met very few of you in person.
 But, my sentiments for this group as a whole are always equated with
 the joy that is now in 

Re: [Server-devel] ToDO: Write up Proxy Strategy

2009-01-13 Thread Martin Langhoff
On Tue, Jan 13, 2009 at 11:42 AM, Caroline Meeks
carol...@solutiongrove.com wrote:
 rproxy - write down what needs to be done and how much.

Caroline and others pointed out today at xocamp that the rproxy notes
were never fully documented. There are some emails on this list about
it - but nothing complete. I've now put it in the wiki
http://wiki.laptop.org/go/XS_Blueprints:rproxy - here's the initial
version for discussion...

Notes on an rproxy implenentation for the XS.

We want to have an optional, easy to switch on rproxy setup on the XS.
rproxy can replace or complement the main XS http proxy - if we have a
stable, efficient, high quality http proxy on the XS, pairing it with
rproxy would be a good idea.

As long as we are using Squid, it's not such a good idea :-(

=Rationale=

rproxy is a proxy that expends HTTP 1.1 proxying and provides much
better performance over very bandwidth constrained linkes. It requires
an upstream rproxy to match the downstream rproxy. For deployments
where the schools are connected to the internet with very limited
uplinks, rproxy can be a huge win.

Modern internet is made of moderately dynamic content --- the content
is mostly static but un-cacheable due to rotating banners or latest
news boxes on the side. Even when content changes, the template for
the content is often 80% of the HTML downloaded. rproxy provides huge
gains with such content.

More about what rproxy is
* http://rproxy.samba.org/
* http://ozlabs.org/~rusty/rproxy.html

=How it would work=

For a deployment with limited connectivity into the schools

 - setup a co-located rproxy server at the ISP
 - enable rproxy on the XSs deployed, pointing to the ISP

Note: the rproxy server at the ISP must only accept requests from
valid clients - either from a defined netblock or whitelisted IP
addresses. An open rproxy is an open proxy!

=Issues with rproxy=

* The working version uses an old version of librsync - which may have
odd bugs and is generally unsupported, untouched, unknown
* There's a half-finished port to the new librsync. Martin Poole
started it a while ago, and abandoned it.
* Does not stream the content through - blocks until the content is
fully fetched before delivery to requester.
* Unknown performance and memory footprint when hit by many users concurrently
* Needs packaging, init scripts, etc...
* Unclear if it behaves reasonably well with ajax streamed requests
- it may break or add problematic latencies, etc

=TO DO=

* Test and ensure it works with modern internet usage patterns. Gmail,
youtube, etc...
* package, configuration, init scripts...
* Test under load, paired with a conventional http proxy - may need
performance / memory trimming
* Port to modern librsync
* Make it work with streamed content (possibly the hardest task!)


...

cheers,



martin
-- 
 martin.langh...@gmail.com
 mar...@laptop.org -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] ToDO: Write up Proxy Strategy

2009-01-13 Thread Martin Langhoff
On Tue, Jan 13, 2009 at 5:59 PM, Martin Langhoff
martin.langh...@gmail.com wrote:
 http://wiki.laptop.org/go/XS_Blueprints:rproxy -

and lest I forget - http://dev.laptop.org/ticket/7815

cheers,


m
-- 
 martin.langh...@gmail.com
 mar...@laptop.org -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


[Server-devel] interest in new proxy

2009-01-13 Thread Vivek Pai
Hi,

My name is Vivek Pai and I'm new to the list. Forgive
me if I'm missing anything relating to this query.

A long time ago, I visited OLPC to discuss HTTP proxy
needs for the schools, and our research group at Princeton
had a project that looked like it might be a good fit. In
particular, it's a Web proxy that scales to large storage
sizes without requiring large memory consumption. It can,
for example, use a 1TB USB drive as a store, while requiring
only a XO-class laptop to drive it.

Is there interest in something like this for the XS server?
We're also working on a WAN accelerator that uses this
proxy, providing transparent compression of content, even
for dynamic Web sites.

The original ticket for this was
https://dev.laptop.org/ticket/6#comment:8

-Vivek

___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] interest in new proxy

2009-01-13 Thread Reuben K. Caron
Vivek,

This sounds very interesting. Could you provide us with more information?

Regards,
Reuben

Vivek Pai wrote:
 Hi,

 My name is Vivek Pai and I'm new to the list. Forgive
 me if I'm missing anything relating to this query.

 A long time ago, I visited OLPC to discuss HTTP proxy
 needs for the schools, and our research group at Princeton
 had a project that looked like it might be a good fit. In
 particular, it's a Web proxy that scales to large storage
 sizes without requiring large memory consumption. It can,
 for example, use a 1TB USB drive as a store, while requiring
 only a XO-class laptop to drive it.

 Is there interest in something like this for the XS server?
 We're also working on a WAN accelerator that uses this
 proxy, providing transparent compression of content, even
 for dynamic Web sites.

 The original ticket for this was
 https://dev.laptop.org/ticket/6#comment:8

 -Vivek

 ___
 Server-devel mailing list
 Server-devel@lists.laptop.org
 http://lists.laptop.org/listinfo/server-devel
   

___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] interest in new proxy

2009-01-13 Thread Martin Langhoff
On Tue, Jan 13, 2009 at 6:39 PM, Vivek Pai vi...@cs.princeton.edu wrote:
 A long time ago, I visited OLPC to discuss HTTP proxy
 needs for the schools, and our research group at Princeton
 had a project that looked like it might be a good fit.

Hi Vivek,

is it your original hashcache or related to it? There was discussion a
while ago of using hashcache - jg was very excited about it, and I was
too. We're pretty disappointed with Squid's performance and memory
usage.

 Is there interest in something like this for the XS server?

Yes yes yes. It'd be fantastic. What is the licensing status?

cheers,



martin
-- 
 martin.langh...@gmail.com
 mar...@laptop.org -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] interest in new proxy

2009-01-13 Thread Vivek Pai
Hi Reuben,

The system is called HashCache, and it's a relatively recent development.
We'd been corresponding with Jim Gettys and trying to get the license
worked out with Eben Moglen.

Jim knows the details, but it's basically a proxy built on a new storage
engine that's optimized to reduce memory consumption. In its most
minimal form, it uses no RAM for the object index, which is what
allows us to do the 1TB disk / 256MB RAM configuration. Its
performance in this configuration is comparable to Squid, since
HashCache has a custom user-level filesystem.

It doesn't compete on features with Squid, but it should be possible
to integrate the necessary set of features.

-Vivek

Reuben K. Caron wrote:
 Vivek,

 This sounds very interesting. Could you provide us with more information?

 Regards,
 Reuben

 Vivek Pai wrote:
   
 Hi,

 My name is Vivek Pai and I'm new to the list. Forgive
 me if I'm missing anything relating to this query.

 A long time ago, I visited OLPC to discuss HTTP proxy
 needs for the schools, and our research group at Princeton
 had a project that looked like it might be a good fit. In
 particular, it's a Web proxy that scales to large storage
 sizes without requiring large memory consumption. It can,
 for example, use a 1TB USB drive as a store, while requiring
 only a XO-class laptop to drive it.

 Is there interest in something like this for the XS server?
 We're also working on a WAN accelerator that uses this
 proxy, providing transparent compression of content, even
 for dynamic Web sites.

 The original ticket for this was
 https://dev.laptop.org/ticket/6#comment:8

 -Vivek

 ___
 Server-devel mailing list
 Server-devel@lists.laptop.org
 http://lists.laptop.org/listinfo/server-devel
   
 

 ___
 Server-devel mailing list
 Server-devel@lists.laptop.org
 http://lists.laptop.org/listinfo/server-devel
   

___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] Notes about XS on XO...

2009-01-13 Thread Jerry Vonau
On Thu, 2009-01-08 at 19:05 -0500, Martin Langhoff wrote:

 
  OK lets backup a second, I'm thinking that the OS could be on a SD
  disk/NAND with an external USB harddrive holding most of the write
  intensive directories. thoughts?
 
 My plan is to use a high quality SD card, not NAND (jffs2 complexity,
 slow, small, etc). And the USB hd holding the _large_ directories.
 Some stuff in /var is somewhat write intensive but very small, so a
 lazy commit policy will be just the ticket -- I think all of /var on
 usb might be harder.
 

Just a question, would we be needing a do-it-yourself explanation of the
steps involved, or are we just going to distribute an image that you
could write to a partition? Both?

I have a XO using a 4gig SD card, started life out as
xo-1-olpc-stream-8.2.1-devel_ext3.img, with the XS repos added, yum
installing xs-pkgs, xs-config now... I've ran into some funny dep issues
but brute forced my way round them. I have some notes around, will try
to add them to the wiki at some point. I've excluded the kernel from
being updated at this point, I'll try a newer kernel at some point
later, just waiting for yum to finish and try rebooting this puppy.
Woohoo reboot time... rats network is broken...  

Time to dig/fix,

Jerry 



___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] interest in new proxy

2009-01-13 Thread Ed McNierney
Vivek -

Jim Gettys passed on your information to me (he left OLPC last week) and I'd
be happy to pick up the conversation with you.  Thanks!

- Ed

Ed McNierney
CTO / VP of Engineering
One Laptop per Child
e...@laptop.org
+1 (978) 761-0049


On 1/13/09 9:32 PM, Vivek Pai vi...@cs.princeton.edu wrote:

 Martin Langhoff wrote:
 On Tue, Jan 13, 2009 at 6:39 PM, Vivek Pai vi...@cs.princeton.edu wrote:
   
 A long time ago, I visited OLPC to discuss HTTP proxy
 needs for the schools, and our research group at Princeton
 had a project that looked like it might be a good fit.
 
 
 Hi Vivek,
 
 is it your original hashcache or related to it? There was discussion a
 while ago of using hashcache - jg was very excited about it, and I was
 too. We're pretty disappointed with Squid's performance and memory
 usage.
   
 The proxy part is HashCache. The WAN accelerator doesn't have a name at
 the moment, but it's probably a few months away from beta.
 
 Is there interest in something like this for the XS server?
 
 
 Yes yes yes. It'd be fantastic. What is the licensing status?
   
 I think we'd reached agreement with Eben on something, but
 we're just waiting at this point. Assuming someone on your end
 tells him that you're interested in forging ahead, I guess he'll
 write up the necessary license. It was basically Affero GPL + patent
 license for the GPL version.
 
 -Vivek
 
 ___
 Server-devel mailing list
 Server-devel@lists.laptop.org
 http://lists.laptop.org/listinfo/server-devel


___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] interest in new proxy

2009-01-13 Thread Martin Langhoff
On Tue, Jan 13, 2009 at 9:32 PM, Vivek Pai vi...@cs.princeton.edu wrote:
 write up the necessary license. It was basically Affero GPL + patent
 license for the GPL version.

That sounds like it'd be workable for us. Fantastic news!



m
-- 
 martin.langh...@gmail.com
 mar...@laptop.org -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel


Re: [Server-devel] Notes about XS on XO...

2009-01-13 Thread Martin Langhoff
On Tue, Jan 13, 2009 at 9:31 PM, Jerry Vonau jvo...@shaw.ca wrote:
 Just a question, would we be needing a do-it-yourself explanation of the
 steps involved, or are we just going to distribute an image that you
 could write to a partition? Both?

I'd say both ;-)

 I have a XO using a 4gig SD card, started life out as
 xo-1-olpc-stream-8.2.1-devel_ext3.img, with the XS repos added, yum
 installing xs-pkgs, xs-config now... I've ran into some funny dep issues
 but brute forced my way round them. I have some notes around, will try
 to add them to the wiki at some point. I've excluded the kernel from
 being updated at this point, I'll try a newer kernel at some point
 later, just waiting for yum to finish and try rebooting this puppy.
 Woohoo reboot time... rats network is broken...

Cool. Another bit of good news is that I tackled JKatz and he
confessed to having (probably) backported the fixes onto the F9
kernel. So maybe a plain XS install to SD may work too...

cheers,



martin
-- 
 martin.langh...@gmail.com
 mar...@laptop.org -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff
___
Server-devel mailing list
Server-devel@lists.laptop.org
http://lists.laptop.org/listinfo/server-devel