Skip to content

Localization

Toxc edited this page Jun 25, 2026 · 1 revision

Localization

OpenLuaTools stores translation files in:

backend/locales/

The repository includes many locale files, including English, Spanish, French, German, Japanese, Korean, Portuguese, Russian, Chinese, and several community/fun locales.

Adding or updating a locale

  1. Start from backend/locales/en.json.
  2. Copy it to a new locale file, using the locale code as the filename.
  3. Translate values while keeping keys unchanged.
  4. Do not delete required keys.
  5. Run the locale validation script.
  6. Test the language in OpenLuaTools settings.

Locale file rules

  • Keep JSON valid.
  • Keep every translation key from en.json.
  • Do not rename keys unless the code is updated too.
  • Keep placeholders intact.
  • Avoid machine-translated strings that do not make sense in context.
  • Do not put jokes into normal language files; use a dedicated joke/fun locale.

Validation

The repository includes:

scripts/validate_locales.py

Run it before submitting translation changes.

Example:

python scripts/validate_locales.py

Existing locale helpers

The locales folder also includes helper scripts/modules such as:

  • fill_locales.py
  • loader.py
  • manager.lua

Use these to keep translation loading and validation consistent.

Translation review checklist

Before opening a pull request:

  • JSON parses correctly.
  • No keys are missing.
  • No extra accidental keys were added.
  • Placeholders are preserved.
  • UI text fits buttons and labels.
  • Technical terms are translated consistently.

Clone this wiki locally