Difference between revisions of "Activity Team/Activity Development Fedora 17"
(These should be added when there are links to other learning pages, otherwise it is confusing) |
|||
(11 intermediate revisions by 3 users not shown) | |||
Line 3: | Line 3: | ||
==Install Fedora 17== | ==Install Fedora 17== | ||
− | Follow the instructions at the [http://fedoraproject.org/en/get-fedora Fedora page] and install Fedora or run it in | + | Follow the instructions at the [http://fedoraproject.org/en/get-fedora Fedora page] and install Fedora or run it in a virtualized environment. |
==Install Sugar== | ==Install Sugar== | ||
− | Now install Sugar: | + | Now install Sugar, on Fedora this is [[0.96/Notes| Sugar 0.96]]: |
yum groupinstall sugar-desktop | yum groupinstall sugar-desktop | ||
Line 19: | Line 19: | ||
[[File:1 develop activity f17 start sugar emulator.png]] | [[File:1 develop activity f17 start sugar emulator.png]] | ||
+ | |||
+ | [[File:2 develop activity f17 running emulator.png]] | ||
+ | |||
+ | [[File:3 develop activity f17 running emulator 3.png]] | ||
==Modify an Activity== | ==Modify an Activity== | ||
Line 30: | Line 34: | ||
Clone the HelloWorld activity (in the folder helloworld.activity): | Clone the HelloWorld activity (in the folder helloworld.activity): | ||
git clone git://git.sugarlabs.org/hello-world/mainline.git helloworld.activity | git clone git://git.sugarlabs.org/hello-world/mainline.git helloworld.activity | ||
+ | |||
+ | [[File:6 develop activity f17 get helloworld.png]] | ||
+ | |||
If you know restart the sugar-emulator the activity will be available. You can favorite it in the activity-list view in the Home view. | If you know restart the sugar-emulator the activity will be available. You can favorite it in the activity-list view in the Home view. | ||
+ | |||
+ | |||
+ | [[File:7_develop_activity_f17_helloworld_favorite.png]] | ||
+ | |||
+ | |||
+ | [[File:8_develop_activity_f17_helloworld_favorte_2.png]] | ||
+ | |||
+ | |||
+ | [[File:9_develop_activity_f17_helloworld_favorite_3.png]] | ||
+ | |||
+ | |||
+ | [[File:10_develop_activity_f17_run_helloworld.png]] | ||
+ | |||
So the first fun thing to do is to change the HelloWorld Activity to welcome yourself. Just change the activity.py file in the Activity folder with your favorite editor and restart the Activity. You do not need to restart the emulator for that. | So the first fun thing to do is to change the HelloWorld Activity to welcome yourself. Just change the activity.py file in the Activity folder with your favorite editor and restart the Activity. You do not need to restart the emulator for that. | ||
− | If you made it | + | [[File:11 develop activity f17 edit activity 1.png]] |
+ | |||
+ | |||
+ | [[File:12 develop activity f17 edit activity.png]] | ||
+ | |||
+ | |||
+ | [[File:13 develop activity f17 result.png]] | ||
+ | |||
+ | |||
+ | If you made it this far, you have made a big step to becoming an Activity developer using the tools available in Fedora 17. I hope you enjoyed it. |
Latest revision as of 08:31, 23 July 2012
Develop an Activity under Fedora 17
Developing an activity under Fedora has never been so easy. Here are the most basic steps to get you started.
Install Fedora 17
Follow the instructions at the Fedora page and install Fedora or run it in a virtualized environment.
Install Sugar
Now install Sugar, on Fedora this is Sugar 0.96:
yum groupinstall sugar-desktop
For running Sugar under GNOME you can use the 'sugar-emulator' install the package:
yum install sugar-emulator
Start the sugar emulator
You can start the Sugar emulator from the terminal, like:
sugar-emulator
Or you can run it from your launcher like any other application:
Modify an Activity
The Activities you installed earlier with the 'groupinstall' command are installed under '/usr/share/sugar/activities/'. For developing it is easier to have them available in a user accessible part of the system. Sugar does look in the $HOME/Activities folder for Activities. The folder has to be named to end with '.activity'.
Start a terminal and create the folder in your $HOME directory and change into it:
cd mkdir Activities cd Activities/
Clone the HelloWorld activity (in the folder helloworld.activity):
git clone git://git.sugarlabs.org/hello-world/mainline.git helloworld.activity
If you know restart the sugar-emulator the activity will be available. You can favorite it in the activity-list view in the Home view.
So the first fun thing to do is to change the HelloWorld Activity to welcome yourself. Just change the activity.py file in the Activity folder with your favorite editor and restart the Activity. You do not need to restart the emulator for that.
If you made it this far, you have made a big step to becoming an Activity developer using the tools available in Fedora 17. I hope you enjoyed it.