L20n/Features/Multilocale resources
From MozillaWiki
goals
- create index resource files that load proper resource files per locale
- store source entities that were used to localize the entities in order to enable tools to recognize outdated localization.
example
if(@locale="en-US") { @import("path/to/fr/resource") } if(@locale="en-GB') { @import("path/to/en/resource") }
In this case, we keep a list of imports that depend on the locale being used.
for 3way merge
<phone "Telefon"> <address "Adres"> if (@locale="en-GB"): { <phone "Phone"> <address "Address"> }
In this case we store entities that have been used as a base for translation. This allows us to compare the source entity from en-US locale with the source entity from translated locale and identify entities that were translated against old version of the string.
status
We decided to reuse if with @import for this goal.
if (@locale="fr") { <entity "value"> } and if (@locale="fr") { import("path/to/resource") }
For the latter purpose we're leaning toward storing some sort of .orig file that contains source entities for the 3way-merge.
- gandalf - accepted
- stas - accepted
- pike - ?