Difference between revisions of "An exercise for new contributors"
(updated the intruction for gcompris-qt) |
(updated for cmake) |
||
Line 7: | Line 7: | ||
* Install GNU/Linux on your computer if you don't already have it. | * Install GNU/Linux on your computer if you don't already have it. | ||
* Download and Install the lastest stable version of [http://qt-project.org/downloads QtCreator] for Android | * Download and Install the lastest stable version of [http://qt-project.org/downloads QtCreator] for Android | ||
− | * Get the GCompris code from the Git version control system (or see bellow the GitHub option). | + | * Get the GCompris code from the Kde Git version control system (or see bellow the GitHub option). |
** git clone git@github.com:bdoin/GCompris-qt.git | ** git clone git@github.com:bdoin/GCompris-qt.git | ||
** cd GCompris-qt | ** cd GCompris-qt | ||
* Create a branch for your development | * Create a branch for your development | ||
** git checkout -b exercise | ** git checkout -b exercise | ||
− | * Start QtCreator and open the project file | + | * Start QtCreator and open the project file CMakeLists.txt at the root of the source code |
* Compile and run it. | * Compile and run it. | ||
* Create a new activity using the supplied ''createit.sh'' script. For example, use your nick name as the activity name. | * Create a new activity using the supplied ''createit.sh'' script. For example, use your nick name as the activity name. | ||
Line 19: | Line 19: | ||
* Compile GCompris again in Qt Creator, check you new activity is present | * Compile GCompris again in Qt Creator, check you new activity is present | ||
* Modify the activity to display an image, a rectangle and a text. | * Modify the activity to display an image, a rectangle and a text. | ||
+ | * (Warning, if you add resources in you activity's resource directory you must run ''cmake'' again). | ||
** You can search for code examples in other activities and check the [http://qt-project.org/doc/qt-5/gettingstartedqml.html Qml getting started]. | ** You can search for code examples in other activities and check the [http://qt-project.org/doc/qt-5/gettingstartedqml.html Qml getting started]. | ||
* Add an event to a graphical object so that clicking on it does something visual. | * Add an event to a graphical object so that clicking on it does something visual. |
Revision as of 12:31, 1 June 2014
Exercise
In order to help you practice in the GCompris framework, I propose you to make this little exercise.
Mandatory: GCompris development is done on a GNU/Linux distribution of your choice.
- Install GNU/Linux on your computer if you don't already have it.
- Download and Install the lastest stable version of QtCreator for Android
- Get the GCompris code from the Kde Git version control system (or see bellow the GitHub option).
- git clone git@github.com:bdoin/GCompris-qt.git
- cd GCompris-qt
- Create a branch for your development
- git checkout -b exercise
- Start QtCreator and open the project file CMakeLists.txt at the root of the source code
- Compile and run it.
- Create a new activity using the supplied createit.sh script. For example, use your nick name as the activity name.
- cd src/activities
- ./createit.sh 'my new activity'
- Compile GCompris again in Qt Creator, check you new activity is present
- Modify the activity to display an image, a rectangle and a text.
- (Warning, if you add resources in you activity's resource directory you must run cmake again).
- You can search for code examples in other activities and check the Qml getting started.
- Add an event to a graphical object so that clicking on it does something visual.
- Use git add and git commit to commit your changes locally.
- git add 'my new activity'
- git commit -a
Publish your patch on GitHub
- Create an account on github
- Fork [git@github.com:bdoin/GCompris-qt.git GCompris]
- Look at these instructions
- Code your activity
- Commit the code
- Push it
- git push
- On github send me a pull request