Update.1 activities download script

Chris Hager chris at linuxuser.at
Mon Mar 17 10:52:14 EDT 2008


I've implemented the upgrade script now -- on the next "xo-get update" 
it will ask to update to version 1.2.5 and then it's capable of "xo-get 
upgrade".

When called, it will re-download the upgrade script from 
http://dev.laptop.org/~bert/update-activities.py all 48 hours, save it 
in ~/.xo_get/update-activities.py, and run it without parameters.

Best,
  - Chris


Chris Hager wrote:
> Sorry for posting twice here before, but somehow I didn't receive any 
> devel and sugar mails for 2 days... Now seems to work again. :p
>
> I'm just about implementing the script into xo-get, and I was thinking 
> on how to do it. Either simply integrating it into xo-get.py (xo-get is 
> a 1-file script), or download it on an 'xo-get upgrade' if it's not 
> available. This might be smarter, so changes in the upgrade script can 
> be made without changing xo-get.
>
>
> Bert Freudenberg wrote:
>   
>> ...
>>
>> To save download time, do something like this first:
>>
>> cp -a /usr/share/activities/*.activity /home/olpc/Activities
>>     
>
> Maybe only make symlinks?
>
>   ln -s /usr/share/activities/*.activity /home/olpc/Activities/
>
>   
>> And finally, there is a trick in the script so it connects to the  
>> current Sugar session even if run from the console or via ssh - may be  
>> useful to somebody:
>>
>> if not 'SUGAR_PREFIX' in os.environ:
>>    """Connect to running Sugar session"""
>>    cp = ConfigParser()
>>    cp.read(env.get_profile_path('session.info'))
>>    os.environ['DBUS_SESSION_BUS_ADDRESS'] = cp.get('Session',  
>> 'dbus_address')
>>    dbus.set_default_main_loop(dbus.mainloop.NULL_MAIN_LOOP)
>>     
>
> Thanks a lot, this is really useful for me already! Maybe also put it 
> somewhere in the wiki... [[Programming Tricks]] :)
>
>
> - Chris
>
> _______________________________________________
> Devel mailing list
> Devel at lists.laptop.org
> http://lists.laptop.org/listinfo/devel
>
>
>   




More information about the Devel mailing list