git-manpages-l10n icon indicating copy to clipboard operation
git-manpages-l10n copied to clipboard

Pretranslate with strings from git

Open jnavila opened this issue 6 years ago • 7 comments

Some parts of git inline help are very close to the documentation strings. This task could be applied to all available languages in git and could help kickstart translations in other languages.

jnavila avatar Aug 08 '19 13:08 jnavila

"translate toolkit" provides a utility name pretranslate that can do the job.

jnavila avatar Aug 08 '19 13:08 jnavila

I've just done a quick test-run with po/documentation.de.po from current master and de.po from git/git's current master. The command I ran was

pretranslate po/documentation.de.po -t de.po -o po/documentation.de.po.

It works, but needs manual review (a carefull git add -p, probably). It marks all strings, even exact matches and unchanged strigs as fuzzy.

rimrul avatar Aug 09 '19 13:08 rimrul

OK; so this is at most a one-time process. I haven't tested for French. Do you think it's worth it?

jnavila avatar Aug 09 '19 14:08 jnavila

Yes, but I'm still thinking of a way to filter out the changes that are just marking an existing string as fuzzy.

Also it's probably more of a once every couple git releases thing.

rimrul avatar Aug 09 '19 15:08 rimrul

I used the following line:

$ pretranslate -t po/documentation.fr.po -i po/documentation.pot --tm=../git/po/fr.po -o po/documentation.pre.fr.po

In fact, I think that's exactly the way it has to be used for new versions of po/documentation.pot

jnavila avatar Aug 09 '19 18:08 jnavila

I did it for es_MX and ru.

jnavila avatar Aug 14 '19 11:08 jnavila