Translations

Brian Riley edited this page Sep 26, 2018 · 21 revisions

Overview

DMPRoadmap uses the FastGettext gem for managing internationalization. The FastGettext files are located in config/locale and consist of a master app.pot file and separate [language_code]/app.po files for each translation.

Several of the gems we use however continue to use the standard Rails I18n system so their specific translations files continue to reside in the config/locales/ directory.

Every language must have corresponding files for FastGettext and I18n.

For a list of currently supported languages, please refer to the ./config/locale directory.

To add a new language or update an existing translation you can follow one of two routes. The first is via an online web portal system called Pootle and the other is to manually update the app.po file directly. Please refer to the following sections for instructions:

Standards

You should use the ISO 639-1 language codes when creating a new translation. If you need/want to create a country specific variation for one of the ISO 639 macro-languages you should use the ISO 3166 2 character alpha codes to designate the country/region.

For example en is the ISO 639 code for English and en-US and en-GB are the ISO 3166 country code specific variations for the United States and Great Britain. If you are uncertain which code to use, please contact the DMPRoadmap project team.

Please note that FastGettext uses an underscore for its file names and not a dash (e.g. en_GB instead of en-GB)

You can’t perform that action at this time.
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.
Press h to open a hovercard with more details.