Synching with default template
[koha.git] / misc / translator / translator_doc.txt
1 TRANSLATION TOOL, V3.0:
2 ======================
3
4 This transation tool should greatly help Koha translators. It's composed of
5 2 scripts:
6
7   * xgettext.pl, that extracts the texts in a template, and which is called by
8     the script
9   * tmpl_process3.tmpl, which can do 3 things:
10       + create a file with all the "translatable strings" in all files in a
11         directory (& its subdirectories)
12       + update an existing translation file.
13       + rebuild translated templates from english & translation file.
14
15 Call tmpl_process3.pl --help to get a more detailed explanation. Some
16 additional explanations are also available by calling perldoc tmpl_process3.pl.
17
18 HOW TO TRANSLATE Koha:
19 =====================
20
21  1. Create your translation file (assuming your current directory is this
22     directory, i.e., misc/translator):
23    
24         ./tmpl_process3.pl create -i ../../koha-tmpl/opac-tmpl/default/en/ -s css_opac_fr_FR.po -r
25    
26     (In the above example, ../../koha-tmpl/opac-tmpl/default/en/ contains the
27     English templates in the "default" theme, and po/css_opac_fr_FR.po is where
28     you want the generated PO file to appear. The use of relative paths for the
29     English templates is recommended but is not necessary; it makes the
30     resulting PO files somewhat easier to read.)
31  2. Translate your css_opac_fr_FR.po file using a text editor or a PO file
32     translation tool.
33  3. Create your translated templates:
34    
35         ./tmpl_process3.pl install -i ../../koha-tmpl/opac-tmpl/default/en/ -o ../../koha-tmpl/opac-tmpl/default/fr2/ -s css_opac_fr_FR.po -r
36    
37     (In the above example, /home/paul/koha.dev/koha/koha-tmpl/opac-tmpl/default
38     /fr2/ is where you want your translated templates to be saved.)
39  4. Copy images/css files in your new directory (as they are NOT moved by
40     tmpl_process3.pl install).
41
42 If something changes in English version:
43
44  1. Update your translation file:
45    
46         ./tmpl_process3.pl update -i ../../opac-tmpl/default/en -s po/css_opac_fr_FR.po -r
47    
48  2. Translate your new css_opac_fr_FR.po file. Look for strings marked as
49     "fuzzy" and strings that are not translated.
50  3. Create your translated templates:
51    
52         ./tmpl_process.pl install -i ../../koha-tmpl/opac-tmpl/default/en/ -o ../../koha-tmpl/opac-tmpl/default/fr2/ -s po/css_opac_fr_FR.po -r
53    
54  4. Copy new images/css files in your new directory if needed
55  
56 REBUILD ALL
57 ===========
58 The rebuild_lang.sh script can be used to rebuild all languages officially supported in 2.2 release, when needed.
59 Useful for developpers, probably useless for all end-users.
60
61
62 WEAKNESSES
63 ==========
64
65 For a somewhat up-to-date list of weaknesses, please run perldoc xgettext.pl
66 and perldoc tmpl_process3.pl and read the BUGS sections.
67
68 COPYRIGHT
69 =========
70
71   * Paul Poulain (paul.poulain _@_ free.fr) & Jerome Vizcaino (vizcainj _@_
72     esiee.fr)
73   * Parts of V3.0 by Ambrose Li (acli _@_ ada.dhs.org)