~communitycouncil/ubuntu-codeofconduct/trunk

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
This document, aimed at both translators and maintainers, provides information
on how to:

- Set up and maintain translations for the Ubuntu Code of Conduct
- Translate the Ubuntu Code of Conduct

Requirements:
 * The po4a package

You can install it by running:
  sudo apt-get install po4a

For maintainers
===============

Updating translatable messages
------------------------------

Whenever there is an update to the Code of Conduct, you'll need to refresh
the translatable messages to expose the new ones to translators in Launchpad.

This can be done in two easy steps:

1. Refreshing the translatable messages in the translation template
2. Committing the translation template

You can refresh translatable messages by running the following command in the
top level folder of the CoC code:

    ./translate.sh

This command will update the po/CodeOfConduct.pot file, known as the
translation template, with the new translatable messages.

As the final step, you need to commit the generated translation template.
Once done, Launchpad willl take care of all the rest.

It is advisable that once you've updated the translatable messages you
notify translators to let them know the translations need to be updated too.

You can do this by reaching out to the Ubuntu Translations team in any of the
ways listed on:

  https://wiki.ubuntu.com/Translations/Contact

Creating translated files
-------------------------

You can use the same command to create translated files from the original
master document in English. Translations will be provided in the form of
gettext .po files in the po directory via Launchpad's auto-commit feature:

    ./translate.sh

For every .po file provided, the command will output a translated .txt file
under the translations directory.

By default, translated .txt files will be created regardless of the
translation coverage in the .po files. If you want to create translated files
only for those languages that have reached a particular percentage of
translation (e.g. 80%) you can:

- either modify the po4a.cfg file and modify this
  line to specify a percentage other than 0:

    [options] opt:"-k 0"

- or pass the "-k n" option when invoking po4a, where n is the threshold
  percentage over which a translated file will be created

For translators
---------------

To translate the Ubuntu Code of Conduct go to:

  https://translations.launchpad.net/ubuntu-codeofconduct

If you want to create translated files from your translations, check out the
'Creating translated files' section in this document.

Happy translating!