While that is a legitimate question, it does not pinpoint what
version of an Activity a particular user has. He might have
installed a different customization, he might have run "software
update", or due to a local error an available version of an Activity
might have failed to be installed. In my opinion the most reliable
way is to look at Activities/foobar.activity/activity/activity.info.
Unfortunately, not all Activity authors have taken the trouble to
update this file when they make changes to the Activity. [And there
have also been Activity authors who did not bother to create an
"-number' for their .xo bundle's filename when they made changes to
the Activity.] Thus identifying the activity version is sometimes a
guessing game.
What I have been using on my XOs is a script which shows the version
number kept in Sugar's "activity registry" (this value is copied
from the respective activity.info files). [While working with Sugar
0.82 and earlier, this script has not worked with Sugar 0.83.]
mikus
#!/usr/bin/env python
import sys
from ConfigParser import ConfigParser
import locale
import os
import tempfile
from sugar.bundle.bundle import Bundle, MalformedBundleException
from sugar import activity
from sugar import env
from sugar.bundle.activitybundle import ActivityBundle
from dbus.mainloop.glib import DBusGMainLoop
DBusGMainLoop(set_as_default=True)
activities = activity.get_registry().get_activities()
for a in activities:
print "Name = ", a.name, "== ", a.bundle_id, ", Version = ", a.version
_______________________________________________
Testing mailing list
[email protected]
http://lists.laptop.org/listinfo/testing