Using AMOS tool for language pack translation

The merge tool supports new translated strings only?

 
Picture of Zhigang Sun
The merge tool supports new translated strings only?
by Zhigang Sun - Monday, 4 April 2011, 3:34 PM
Language pack maintainers

Hi, david

After the creation of 2.1dev branch, in zh-cn 2.0, there are three submissions. One of them contains 32 new translated strings and the other two contain modified translation only.

Today, I tried the merge tool to merge from 2.0 to 2.1dev. But it only gave out the new translated strings.  Is this a bug or I didn't use it in the right way?

Yours Sunner

Picture of David Mudrák
Re: The merge tool supports new translated strings only?
by David Mudrák - Monday, 4 April 2011, 4:23 PM
Language pack maintainers
Hmm, that's a very good point Sunner... The merge tool can copy the strings that do not exists on the target branch yet. That is intentional to protect against accidental overwriting of some strings. But that means there is no easy way how to pick a contributed fix for 2.0 branch and re-apply it automatically for other branch(es) ...

This is a very strong use case and must be fixed asap. Thanks for letting me know!
Picture of Zhigang Sun
回复: Re: The merge tool supports new translated strings only?
by Zhigang Sun - Monday, 4 April 2011, 10:13 PM
Language pack maintainers

Is it possible to use the timestamp of every string?

For example, two strings with the same id are included in both 2.0 and 2.1dev branch. If their original contents are identical, then it is safe to merge from a newer translation. Otherwise, there should be an alert to mergers.

Picture of David Mudrák
Re: 回复: Re: The merge tool supports new translated strings only?
by David Mudrák - Tuesday, 5 April 2011, 12:12 AM
Language pack maintainers
Well, not really. Now when strings are correctly branched, Moodle developers can modify the string for a given branch only. For example strings can be reworded for 2.1 without affecting 2.0. This was not possible in Moodle 1.x because we used a single branch for translations of all Moodle versions. So we had to introduce new strings instead of altering the current ones.

Hmm, although... The merge tool could check the original English text. If it is identical at several consequent branches and there is a modification in a translation of one of them, it is reasonable to assume that the maintainer wants to accept the change for all branches.

Example: let us have a string [foo,mod_bar] that has the English text "Foo" at 2.0 and 2.1 branches but "Frog" at 2.2 branch. It is translated as "Bar" at all three branches. A contributor submits a translation that changes the translation at the branch 2.0 from "Bar" to "Beer". There should be a way (probably at the stage page) to propagate such change to 2.1, too. But the propagation must not affect the 2.2 branch.

So I can see it as a button "Clone translations" at the stage page that would do this job for all staged strings. Ideas? Contra-proposals?
Picture of Zhigang Sun
回复: Re: 回复: Re: The merge tool supports new translated strings only?
by Zhigang Sun - Tuesday, 5 April 2011, 12:29 PM
Language pack maintainers

If the idential strings have exact same meaning in all the branches, perhaps there is no problem. But if they have only the same hex value, it is a problem. For example, the string [grade, core] has been widely used accross moodle for a long time. The word grade can be noun or verb in English. So it is safe to use it to show grade point or lable a button to grade in English UI. But in Chinese, the noun translation is 成绩, and verb translation is 评分. They are totally different.