Hello.
Some time ago I have successfully generated a .pot-file and two
.po-files for help-system of a Gretl program (a part of a GNU project
-
gretl.sf.net) which is in two xmls
I used these versions of files:
http://gretl.cvs.sourceforge.net/viewvc/*checkout*/gretl/gretl/doc/comman...
http://gretl.cvs.sourceforge.net/viewvc/*checkout*/gretl/gretl/doc/comman...
I used the following config file to do this:
[po4a_paths] doc/i10n/gretl_help.pot ru:doc/i10n/ru.po pt_BR:doc/i10n/pt_BR.po
[type: xml] doc/genr_funcs.xml ru:doc/ru/genr_func_ru.xml
pt_BR:doc/pt_BR/genr_func_pt_BR.xml\
opt:"-o 'translated=<para> i<para><lit>
i<para><math> \
i<para><argname> i<para><quote> i<para><cmdref>
i<para><guideref> \
i<para><fncref> i<para><sub> i<para><sup>
i<para><repl> \
i<para><quote><lit>' \
-o 'untranslated=<repl> \
<example> <emphasis> \
<code> <fnarg>'"
[type: xml] doc/gretl_commands.xml ru:doc/ru/gretl_commands_ru.xml
pt_BR:doc/pt_BR/gretl_commands_pt_BR.xml\
opt:"-o 'translated=<para> i<para><lit>
i<para><math> i<para><quote>\
i<para><emphasis> i<para><repl> i<para><cmdref>
i<para><book> \
i<para><guideref> i<para><cmd> \
i<para><sub> i<para><sup> i<para><program>\
<menu-path> <effect>' \
-o 'untranslated=<argument> <flag> \
<code> <demo> <example> <lit> <table> <cell>
<repl> \
<optparm> <filename> <math>'"
I have uploaded them on
launchpad.net and we translated some parts of
them. Now we want to update our .pot and .po-files (ru and pt_BR) with
the new version of one of the xmls. The other file wasn't changed. So
new files are:
http://gretl.cvs.sourceforge.net/viewvc/*checkout*/gretl/gretl/doc/comman...
http://gretl.cvs.sourceforge.net/viewvc/*checkout*/gretl/gretl/doc/comman...
Also I uderstand that I need to add two tags for inline translation
for unchanged gretl_funcs.xml. So the config file should look like
this:
[po4a_paths] doc/i10n/gretl_help.pot ru:doc/i10n/ru.po pt_BR:doc/i10n/pt_BR.po
[type: xml] doc/genr_funcs.xml ru:doc/ru/genr_func_ru.xml
pt_BR:doc/pt_BR/genr_func_pt_BR.xml\
opt:"-o 'translated=<para> i<para><lit>
i<para><math> \
i<para><argname> i<para><quote> i<para><cmdref>
i<para><guideref> \
i<para><fncref> i<para><sub> i<para><sup>
i<para><repl> \
i<para><quote><lit> i<para><equation>
i<para><by>' \
-o 'untranslated=<repl> \
<example> <emphasis> \
<code> <fnarg>'"
[type: xml] doc/gretl_commands.xml ru:doc/ru/gretl_commands_ru.xml
pt_BR:doc/pt_BR/gretl_commands_pt_BR.xml\
opt:"-o 'translated=<para> i<para><lit>
i<para><math> i<para><quote>\
i<para><emphasis> i<para><repl> i<para><cmdref>
i<para><book> \
i<para><guideref> i<para><cmd> \
i<para><sub> i<para><sup> i<para><program>\
<menu-path> <effect>' \
-o 'untranslated=<argument> <flag> \
<code> <demo> <example> <lit> <table> <cell>
<repl> \
<optparm> <filename> <math>'"
When I simply try to launch a po4a with a new config file and existing
old .pot and .po-files I receive a message about 1485 strings in
.pot-file. And it should contain 1476 strings with the new
config-file. 1485 is the number of strings from the existing .pot
file. AFAIU it is not updated with new tags for inline translation. My
.pot-file and two .po-files are in the attachment.
Thanks a lot for such a program. With "-k 0" option I can produce now
a translated versions of these xmls and this is already something.
With respect, Ivan Sopov.
P.S. Actually the pt_BR.po file was generated from a .pot-file on the launchpad.