Translation Guidelines
The translations are hosted on Weblate thanks to their free Libre tier.
Currently, only FMD Android can be translated. FMD Server is not yet set up to be translatable, please follow this issue.
Basic workflow
The source language is English, located in values/strings.xml
.
English translations should always be manually committed to GitLab to keep the file clean and organised.
English is synced up from GitLab to Weblate, using a webhook on every commit to main.
That is, Weblate should automatically pick up changes on main.
All other languages should be added and edited on Weblate. They are then synced down from Weblate to GitLab. Weblate will automatically open Merge Requests for them.
Things to keep in mind
- Use the informal form for addressing the user. E.g. in German use lower-case "du" instead of "Sie".
- Use sentence case (see https://m3.material.io/foundations/content-design/style-guide/ux-writing-best-practices)
- Don't translate changelogs. For now, we keep them English-only.
The following are fixed names and should be used as-is in other languages:
- FMD, FMD Android, FMD Server
- OpenCelliD
Fixing translation conflicts
This section is for devs, you won't need this as a translator.
TLDR:
git remote add weblate https://hosted.weblate.org/git/fmd/fmd-android
git checkout -b fix-weblate
git remote update weblate
git merge --strategy-option theirs weblate/master
git push --set-upstream origin fix-weblate
Sometimes there are conflicts with Weblate (and it is not always clear where they come from...).
To fix them, follow Weblate's instructions here: https://docs.weblate.org/en/latest/faq.html#merge. There are two exceptions: use a merge strategy, and don't rebase.
When you do the merge, you will get conflicts. Manually trying to resolve them will not always work straight away. Therefore the recommended option is to tell git so automatically resolve the conflicts in favour of what the Weblate branch has:
git merge --strategy-option theirs weblate/master
To check that this worked, and that there are no more conflicts, simply merge a second time: git merge weblate/master
.
This should print Already up-to-date.
.
Also, don't rebase (as per Weblate instructions). Instead, just do all of this on a fresh branch checked out on top of master.
Then push your branch, merge it into master, and unlock Weblate again.