Re: translation infrastructure in need

Marco Ciampa <[email protected]> Thu, 21 May 2026 07:05:06 +0000
Newsgroups gmane.org.fsf.europe.translators
Message-ID <ag6uoEbjtEUGAo8Y@marco-TUXEDO-Pulse-15-Gen2>
Il Wed, May 20, 2026 at 11:15:52AM +0200, Bonnie Mehring ha scritto:
> Hej Marco,
> 
> just to keep you posted. So, we are currently thinking about how to solve
> the issues with the existing translations:
>
> https://status.fsfe.org/xml_structure/index.en.html
> 
> As all of those files will be ignored when generating the .po-files.
> 
> We will keep working on this.

Good. I definitely WILL help on that. I just have to figure it out how
to speed things up instead of doing a:

fork -> pull request ->wait

for N! times!

In the meantime here some exaples of po4a for you:

copy & exec to see how it works:

######################################################################

#!/bin/bash

#Title: gettextize-untranslated-doc-example.sh

sudo apt install po4a

#Get the original
wget https://git.fsfe.org/FSFE/fsfe-website/raw/branch/master/fsfe.org/about/codeofconduct.en.xhtml

po4a-updatepo -f xhtml -A utf-8 -M utf-8 -m codeofconduct.en.xhtml -p it.po

# .... done some translation into -> it-translated.po
# and merged it back:

po4a-translate -f xhtml -A utf-8 -M utf-8 -m codeofconduct.en.xhtml -p it-translated.po -l codeofconduct.it.xhtml -k -0

# -k -0 means disable 80% threshold to produce a translated .po file

#####################################################################

#!/bin/bash

#Title: gettextize-existing-translation-example.sh

sudo apt install po4a

#Get the original
wget https://git.fsfe.org/FSFE/fsfe-website/raw/branch/master/drm.info/act-now.en.xhtml

#Create a .po from an existing doc (it should be correct obviously), this is not
wget https://git.fsfe.org/FSFE/fsfe-website/raw/branch/master/drm.info/act-now.de.xhtml

po4a-gettextize -M utf-8 -L utf-8 -f xhtml -m act-now.en.xhtml -l act-now.de.xhtml -p de.po.

#Partial result: gettextization.failed.po

#This time it is correct
#wget https://git.fsfe.org/FSFE/fsfe-website/raw/branch/master/drm.info/act-now.en.xhtml
wget https://git.fsfe.org/FSFE/fsfe-website/raw/branch/master/drm.info/act-now.it.xhtml
po4a-gettextize -M utf-8 -L utf-8 -f xhtml -m act-now.en.xhtml -l act-now.it.xhtml -p it.po

Hope this helps!


-- 

Amike,
Marco Ciampa
_______________________________________________
Translators mailing list -- [email protected]
To unsubscribe send an email to [email protected]

This mailing list is covered by the FSFE's Code of Conduct. All
participants are kindly asked to be excellent to each other:
https://fsfe.org/about/codeofconduct