~nik90/ubuntu-clock-app/sync-clock-backend

« back to all changes in this revision

Viewing changes to README.translations

  • Committer: Nekhelesh Ramananthan
  • Date: 2013-09-26 20:18:19 UTC
  • mfrom: (200.1.2 trunk)
  • Revision ID: krnekhelesh@gmail.com-20130926201819-fb636k4ouvut9jd5
mergeĀ fromĀ trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# Updating translations
 
2
 
 
3
Translations for the Clock app happen in [Launchpad Translations][] and
 
4
are automatically committed daily on the trunk branch in the po/ folder.
 
5
 
 
6
They are then built and installed as part of the package build, so that
 
7
developers don't really need to worry about them.
 
8
 
 
9
However, there is one task that needs to be taken care of: exposing new
 
10
translatable messages to translators. So whenever you add new translatable
 
11
messages in the code, make sure to follow these steps:
 
12
 
 
13
 1. Change directory to the po/ folder: `cd po`
 
14
 2. Update the translations template: `qmake && make pot`
 
15
 3. Commit the generated .pot file: `bzr commit -m"Updated translation template"`
 
16
 4. Push the branch and send a merge proposal as usual
 
17
 
 
18
And that's it, once the branch lands Launchpad should take care of all the rest!
 
19
 
 
20
# Behind the scenes
 
21
 
 
22
Behind the scenes, whenever the po/*.pot file (also known as translations template)
 
23
is committed to trunk Launchpad reads it and updates the translatable strings
 
24
exposed in the web UI. This will enable translators to work on the new strings.
 
25
The translations template contains all translatable strings that have been
 
26
extracted from the source code files.
 
27
 
 
28
Launchpad will then store translations in its database and will commit them daily
 
29
in the form of textual po/*.po files to trunk. The PO files are also usually
 
30
referred to as the translations files. You'll find a translation file for each
 
31
language the app has got at least a translated message available for.
 
32
 
 
33
Translations for core apps follow the standard [gettext format].
 
34
 
 
35
 [Launchpad Translations]: https://translations.launchpad.net/ubuntu-clock-app
 
36
 [gettext format]: https://www.gnu.org/software/gettext/