You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+42Lines changed: 42 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -20,6 +20,48 @@ Modern vision of the mobile application for the Open edX platform from Raccoon G
20
20
21
21
6. Click the **Run** button.
22
22
23
+
## Translations
24
+
25
+
### Getting Translations for the App
26
+
Translations aren't included in the source code of this repository as of [OEP-58](https://docs.openedx.org/en/latest/developers/concepts/oep58.html). Therefore, they need to be pulled before testing or publishing to App Store.
27
+
28
+
Before retrieving the translations for the app, we need to install the requirements listed in the requirements.txt file located in the i18n_scripts directory. This can be done easily by running the following make command:
29
+
```bash
30
+
make translation_requirements
31
+
```
32
+
33
+
Then, to get the latest translations for all languages use the following command:
34
+
```bash
35
+
make pull_translations
36
+
```
37
+
This command runs [`atlas pull`](https://github.com/openedx/openedx-atlas) to download the latest translations files from the [openedx/openedx-translations](https://github.com/openedx/openedx-translations) repository. These files contain the latest translations for all languages. In the [openedx/openedx-translations](https://github.com/openedx/openedx-translations) repository each language's translations are saved as a single file e.g. `i18n/src/main/res/values-uk/strings.xml` ([example](https://github.com/openedx/openedx-translations/blob/04ccea36b8e6a9889646dfb5a5acb99686fa9ae0/translations/openedx-app-android/i18n/src/main/res/values-uk/strings.xml)). After these are pulled, each language's translation file is split into the App's modules e.g. `auth/src/main/res/values-uk/strings.xml`.
38
+
39
+
After this command is run the application can load the translations by changing the device (or the emulator) language in the settings.
40
+
41
+
### Using Custom Translations
42
+
43
+
By default, the command `make pull_translations` runs [`atlas pull`](https://github.com/openedx/openedx-atlas) with no arguments which pulls translations from the [openedx-translations repository](https://github.com/openedx/openedx-translations).
44
+
45
+
You can use custom translations on your fork of the openedx-translations repository by setting the following configuration parameters:
46
+
47
+
-`--revision` (default: `"main"`): Branch or git tag to pull translations from.
48
+
-`--repository` (default: `"openedx/openedx-translations"`): GitHub repository slug. There's a feature request to [support GitLab and other providers](https://github.com/openedx/openedx-atlas/issues/20).
49
+
50
+
Arguments can be passed via the `ATLAS_OPTIONS` environment variable as shown below:
51
+
```bash
52
+
make ATLAS_OPTIONS='--repository=<your-github-org>/<repository-name> --revision=<branch-name>' pull_translations
53
+
```
54
+
Additional arguments can be passed to `atlas pull`. Refer to the [atlas documentations ](https://github.com/openedx/openedx-atlas) for more information.
55
+
56
+
### How to Translate the App
57
+
58
+
Translations are managed in the [open-edx/openedx-translations](https://app.transifex.com/open-edx/openedx-translations/dashboard/) Transifex project.
59
+
60
+
To translate the app join the [Transifex project](https://app.transifex.com/open-edx/openedx-translations/dashboard/) and add your translations to the
Once the resource is both 100% translated and reviewed the [Transifex integration](https://github.com/apps/transifex-integration) will automatically push it to the [openedx-translations](https://github.com/openedx/openedx-translations) repository and developers can use the translations in their app.
64
+
23
65
## API
24
66
This project targets on the latest Open edX release and rely on the relevant mobile APIs.
0 commit comments