Difference between revisions of "An exercise for new contributors"

From GCompris
Jump to: navigation, search
m (Exercise)
Line 8: Line 8:
 
* Download and Install the latest stable version of [https://www.qt.io/download-open-source/#section-2 QtCreator] (version 5.5.0 recommended)  
 
* Download and Install the latest stable version of [https://www.qt.io/download-open-source/#section-2 QtCreator] (version 5.5.0 recommended)  
 
* Install [https://cmake.org/download/ CMake] (version 3.5.1 recommended)
 
* Install [https://cmake.org/download/ CMake] (version 3.5.1 recommended)
* Get the GCompris code from the Kde Git version control system (or see bellow the GitHub option).
+
* Get the GCompris code from the Kde Git version control system (or see below the GitHub option).
 
** git clone https://github.com/gcompris/GCompris-qt
 
** git clone https://github.com/gcompris/GCompris-qt
 
** cd GCompris-qt
 
** cd GCompris-qt

Revision as of 16:32, 18 May 2017

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 latest stable version of QtCreator (version 5.5.0 recommended)
  • Install CMake (version 3.5.1 recommended)
  • Get the GCompris code from the Kde Git version control system (or see below the GitHub option).
  • Configure you Git username and email
    • git config --global user.email "your_email@example.com"
    • git config --global user.name "FirstName LastName"
  • 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'
  • Update the copyrights of the different files with your name and email.
  • 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).
  • 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:gcompris/GCompris-qt.git GCompris]
  • Code your activity
  • Commit the code
  • Push it
    • git push
  • On github send a pull request