/[d-i]/trunk/manual/translations_po.txt
ViewVC logotype

Contents of /trunk/manual/translations_po.txt

Parent Directory Parent Directory | Revision Log Revision Log


Revision 25593 - (hide annotations) (download)
Sat Feb 12 21:48:14 2005 UTC (8 years, 3 months ago) by fjpop-guest
Original Path: trunk/installer/doc/manual/translations_po.txt
File MIME type: text/plain
File size: 5606 byte(s)
New file explaining how to use .po files to translate the manual (not yet officially supported)
1 fjpop-guest 25593 Debian Installation Manual - notes for translation
2     --------------------------------------------------
3    
4     This file explains how to translate the manual using .po files.
5     This is not yet officially supported yet, but the necessary tools are already
6     available and some languages are already using this method.
7    
8     !!! For general information on translating the manual, please see the
9     !!! translations.txt file.
10    
11     Note: if you happen to modify this file, please don't forget to
12     update the trailing changelog
13    
14     Background information
15     ======================
16     There are currently two toolsets that support translating XML files using .po
17     files: KDE's poxml and po4a. We have chosen poxml as that gives better context
18     (it does not split paragraphs) for translation.
19     The downside of the poxml tools is that they require the .xml files to be
20     "proper" XML. Because some of the individual files in the English
21     original are not proper XML, we've had to "integrate" the files per chapter.
22    
23     This means that instead translating about 160 small files, you will be
24     translating about 15 large files.
25    
26     Current limitations
27     ===================
28     The use of .po files for translating the manual is not yet officially
29     supported. This means that some things that will eventually be automated,
30     will now have to be done manually.
31     You are also not yet allowed to check in your .po files into d-i's SVN
32     repository. Instead you have to check in the integrated translated .xml files
33     that can be created from the .po files.
34    
35     If there is more than one person working on the translation, this means you
36     will have to find some other way to give everybody access to the .po files.
37    
38     Requirements
39     ============
40     You will need to install the following packages on your system:
41     - gettext
42     - poxml
43     - gawk
44    
45     Available tools
46     ===============
47     You will not be using poxml itself, but rather some scripts that call the
48     poxml tools.
49    
50     - ./scripts/merge_xml : merges the small .xml files into larger files
51     - ./scripts/update_pot : creates (new) .pot templates based on integrated
52     English .xml files
53     - ./scripts/update_po : updates your .po files when there are changes in the
54     English text (the .pot templates)
55     - ./scripts/create_xml : creates translated .xml files from the merged English
56     .xml files and the translated .po files
57     - ./scripts/create_po : used to convert an existing .xml translation to
58     using .po files
59    
60     All scripts should be run from the ./manual directory and take the language as
61     parameter.
62    
63     Starting a new translation
64     ==========================
65     Run the following commands:
66     1. ./scripts/merge_xml en
67     2. ./scripts/create_pot
68    
69     The first command will create a directory ./integrated and in that the
70     integrated XML files for English.
71     The second command creates a directory ./po and in that the .pot template
72     files.
73    
74     You can now start translating! Just copy a .pot file to a .<lang>.po file and
75     use your favorite .po file editor (like kbabel) to translate the .po file.
76     You don't need to copy all .pot files to begin with, just copy each one as you
77     start translating them.
78    
79     Example for a Dutch translation:
80     - cp ./po/bookinfo.pot ./po/bookinfo.nl.po
81     - <po editor> ./po/bookinfo.nl.po
82    
83     Committing your translation
84     ===========================
85     Run the following command:
86     1. ./scripts/create_xml <your language>
87    
88     This command will create translated XML files for your language in the
89     ./integrated directory (in a subdirectory for your language).
90     You next have to copy these files to their regular location and commit them
91     to the repository:
92     2. cp -r ./integrated/<your language> .
93     3. svn ci <your language> -m "<some comment describing the changes>"
94    
95     If this is the first time you commit the translation or a file, you will need
96     to run the 'svn add' command on the new files before you do 'svn ci'.
97     Tip: use the commands 'svn st ' and 'svn diff' before you commit your changes
98     to check what you are committing before you run the 'svn ci' command.
99    
100     NOTE
101     You should *not* run 'svn up' between the moment you last updated the .pot
102     templates and your .po files and the moment you create the .xml files for your
103     translation!
104    
105     Updating your translation
106     =========================
107     When there are changes in the original English files, you will need to update
108     your .po files. Changed strings will be marked 'fuzzy' and new strings will be
109     untranslated.
110    
111     Run the following commands:
112     1. svn up
113     2. ./scripts/merge_xml en
114     3. ./scripts/create_pot
115     4. ./scripts/update_po <your language>
116    
117     After this your .po files in the ./po directory should be updated and you can
118     update your translation with your favorite .po file editor. To commit the
119     changes, follow again the procedure described in the previous section.
120    
121     Converting an existing translation from .xml files to .po files
122     ===============================================================
123     It is possible to convert an existing translation of the manual where the
124     individual XML files have been translated to using .po files.
125     There are two important conditions:
126     - the translation must be up-to-date with the English XML files;
127     - the translation must have same structure as the English XML files (i.e.
128     the translation must have the same chapters, sections, paragraphs, tables,
129     examples, etc; you can have no 'extra' paragraphs in your translation).
130    
131     The first condition does not mean that everything needs to be translated!
132    
133     The conversion is fairly difficult and some checks need to be done after some
134     of the steps.
135     If you would like to switch, please contact Frans Pop <aragorn@tiscali.nl>.

  ViewVC Help
Powered by ViewVC 1.1.5