[lfs-fr] LFS Translation

Alberto Senna Dias Neto albertosdneto at gmail.com
Ven 16 Mai 14:36:27 PDT 2014


2014-05-16 17:57 GMT-03:00 amj <amj at tdct.org>:

>  I don't understand why you say that the newlines are errors because if
> you use a poeditor you do not edit directly the po's and the program
> matches the translation with the source.
>
>
The newlines are not error.
In my case, the behavior of keeping all of them in the po file is error
prone.

When I bring the po generated in the po4a to OmegaT ( where I have a
translation memory ) I have a very wierd segmentation because of the
newline.
Sometimes I have only one comma like a segment.

If I use po4a at this moment I woud have to change my entire Translation
Memory to fit this segmentation differences.

So, for me, at this moment, this is error prone, once I can make mistakes
bringing translations from one segment to another or breaking translated
segments.

Po4a is a great tool. I wish I had used that from the very beginning.

Anyway, I stoped using itstool and I am using xml2po.

With the proper parameters ( I have just discovered how importante RTFM is
) I managed to solve the problems with tags I had.

I am doing this way to create po files (sorry if the scripts are not
mature):
*******************
#!/bin/bash

for i in *.xml; do
  echo $i

  xml2po -k -m docbook -o ${i/xml/po} $i

  echo ${i/xml/po}
done

for i in *.xml; do
  echo $i

  mv $i ${i/xml/en.xml}

  echo ${i/xml/en.xml}
done

************

And this way to merge translated po with xml:
*****************
#!/bin/bash
for i in *en.xml; do
  echo $i

  xml2po -k -p ${i/en.xml/po} -o ${i/en.xml/xml} $i

  echo ${i/en.xml/xml}
done

*******************

Regards.

-- 
Alberto Senna Dias Neto
albertosdneto at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxfromscratch.org/pipermail/lfs-traducfr/attachments/20140516/b39b3580/attachment.html>


More information about the lfs-traducfr mailing list