Solved Many Conflicts after Merging TS Files
-
Hi everyone,
we are using ts files for internationalization. We support 17 languages.
It happens quite often, when we work on different branches, that we have conflicts in ts files when we merge different branches and it gets even more complicated, because we have to fix the merge conflicts for 17 ts files which is quite troublesome.So my question is, if there is a good solution to overcome this problem.
How are you dealing with this problem? -
Hi,
Do you mean you are working on new feature in several different branches and do the translations in these branches before merging them back into master ?
-
Yes, that's right, because a branch can live for several weeks.
-
Since you have so many languages, one nontechnical solution might be to follow a specific strategy when dealing with strings. Something like:
- Have the developers work on translatable code without doing the translations at the same time
- Merge branches as usual
- Have a string freeze (meaning the code can still change but not the texts)
- Do the translations in a branch while the works continue on the other
- Merge branches as usual
- Merge the translation branch
-
@SGaist said in Many Conflicts after Merging TS Files:
- Have the developers work on translatable code without doing the translations at the same time
- Merge branches as usual
- Have a string freeze (meaning the code can still change but not the texts)
- Do the translations in a branch while the works continue on the other
- Merge branches as usual
- Merge the translation branch
This is exactly how the Qt Project manages translations :)
The "string freeze" is the most important part: This makes sure that the text is not allowed to change after translations begin, so conflicts will not happen in the *.ts files.
-
Ok, thx for the advice, guys! :-)