Continuing on my tests mission
[koha.git] / misc / translator / translator_doc.html
1 <h1>TRANSLATION TOOL, V3.0:
2 <br>======================</h1>
3
4 <p>
5 This transation tool should greatly help Koha translators.
6 It's composed of 2&nbsp;scripts
7 (with a number of associated perl module files):
8
9 <ol>
10 <li>xgettext.pl, that extracts the texts in a template,
11     and which is called by the script; and
12 <li>tmpl_process3.tmpl, which can do 3 things:
13     <ol type=a>
14     <li>create a file with all the "translatable strings" in all files in a directory (& its subdirectories),
15     <li>update an existing translation file, and
16     <li>rebuild translated templates from English & translation file.
17     </ul>
18 </ul>
19 <p>
20 Call tmpl_process3.pl --help to get a more detailed explanation.
21 Some additional explanations are also available by calling
22 perldoc tmpl_process3.pl.
23
24 <h2>HOW TO TRANSLATE Koha:
25 <br>=====================</h2>
26
27 <ol>
28 <li>Create your translation file
29     (assuming your current directory is this directory, i.e., misc/translator):
30     <blockquote>
31 ./tmpl_process3.pl create -i ../../koha-tmpl/opac-tmpl/default/en/ -s po/css_opac_fr_FR.po -r
32     </blockquote>
33     <p>(In the above example,
34     ../../koha-tmpl/opac-tmpl/default/en/
35     contains the English templates in the "default" theme,
36     and po/css_opac_fr_FR.po is where you want the generated PO file to appear.
37     The use of relative paths for the English templates is recommended;
38     it makes the resulting PO files slightly shorter
39     and more usable in a team environment.
40     Absolute paths are certainly fine,
41     and might be better if there is only one translator for your language.)
42 <li>Translate your css_opac_fr_FR.po file
43     using a text editor or a PO file translation tool.
44 <li>Create your translated templates:
45     <blockquote>
46 ./tmpl_process3.pl install -i ../../koha-tmpl/opac-tmpl/default/en/ -o /home/paul/koha.dev/koha/koha-tmpl/opac-tmpl/default/fr2/ -s po/css_opac_fr_FR.po -r
47     </blockquote>
48     <p>
49     (In the above example,
50     /home/paul/koha.dev/koha/koha-tmpl/opac-tmpl/default/fr2/
51     is where you want your translated templates to be saved.)
52 <li>Copy images/css files in your new directory (as they are NOT moved by tmpl_process3.pl install).
53 </ol>
54
55 <p>
56 If something changes in the English version:
57 <ol>
58 <li>Update your translation file:
59     <blockquote>
60 ./tmpl_process3.pl update -i ../../koha-tmpl/opac-tmpl/default/en/ -s po/css_opac_fr_FR.po -r
61     </blockquote>
62 <li>Translate your newly updated css_opac_fr_FR.po file.
63     Look for strings marked as "fuzzy" and strings that are not translated.
64 <li>Create your translated templates:
65     <blockquote>
66 ./tmpl_process3.pl install -i ../../koha-tmpl/opac-tmpl/default/en/ -o /home/paul/koha.dev/koha/koha-tmpl/opac-tmpl/default/fr2/ -s po/css_opac_fr_FR.po -r
67     </blockquote>
68 <li>Copy new images/css files in your new directory if needed
69 </ol>
70
71 <h2>WEAKNESSES
72 <br>==========</h2>
73 <p>For a somewhat up-to-date list of weaknesses,
74 please run <code>perldoc xgettext.pl</code>
75 and <code>perldoc tmpl_process3.pl</code>
76 and read the BUGS sections.
77
78 <h2>COPYRIGHT
79 <br>=========</h2>
80 <ul>
81 <li>Paul Poulain (paul.poulain _@_ free.fr) & Jerome Vizcaino (vizcainj _@_ esiee.fr)
82 <li>Parts of V3.0 by Ambrose Li (acli _@_ ada.dhs.org)
83 </ul>