dolibarr-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Dolibarr-dev] Translation clean-up primary/secondary language


From: Doursenaud , Raphaël
Subject: Re: [Dolibarr-dev] Translation clean-up primary/secondary language
Date: Mon, 19 May 2014 15:17:26 +0200

Hi Oli,

Didn't test your work yet but it sure will be a nice addition to the translation toolbox. Congratulations!

Developers scripts are usually stored under the "dev" directory at the Dolibarr's project root. I'd put your script into "dev/translation".

A nice addition would be to also check all "primary" languages against the en_US reference language. I'm sure there are a bunch of errors there as well.

Ultimately, we'd need a tool that understand the multiple "langs" calls in PHP files, extracts all the "translation keys", and check that the reference language have them. Add this to our CI server and we'd have the ultimate language verification toolbox!

Cheers,


2014-05-16 23:12 GMT+02:00 Oli Sennhauser <address@hidden>:
Hello all

I wrote a little PHP script to clean-up secondary language translations (e.g. de_AT). It finds some nice errors in primary and secondary language translations... :-)

Task: Can you please test the clean-up script for your specific language and give me your feedback (especially errors!)?

Candidates to test are: de_AT, en_XX (XX != US), es_XX (XX != ES), fr_XX (XX != FR) nl_XX (XX != ?) pt_XX (pt != PT), ru_XX (XX != RU?), zh_XX (XX != ?).

I tried to do it in a way that also non-latin languages should work. Please let me know if there are problems (arabic, hebrew, cyrillic, JKC, etc.)

Question: where should this script be stored/kept? Would it be interesting for other multi-lingual projects as well?

Usage:

./strip_language_file.php langs/de_DE/admin_primary.lang langs/de_AT/admin_secondary.lang
File langs/de_DE/admin.lang:
Key DispenseMontantLettres is redundant in file langs/de_DE/bills.lang (line: 218).
----
File langs/de_AT/admin.lang:
ERROR in file langs/de_AT/admin.lang, line 2: * Language code: de_AT
Key ModulesJob does NOT exist in primary language (line: 79).
Output can be found at langs/de_AT/admin.lang.delta.

It might also be necessary that you clean-up your primary language as well. So please study the error messages carefully

Please let me know what you think about and the results...

Regards,
Oli

_______________________________________________
Dolibarr-dev mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/dolibarr-dev




--
Raphaël Doursenaud
Directeur technique (CTO)
Expert certifié en déploiement Google Apps
+33 (0)5 35 53 97 13 - +33 (0)6 68 48 20 10

http://gpcsolutions.fr
Technopole Hélioparc
2 avenue du Président Pierre Angot
64053 PAU CEDEX 9
SARL GPC.solutions au capital de 7 500 € - R.C.S. PAU 528 995 921

reply via email to

[Prev in Thread] Current Thread [Next in Thread]