Skip to content

Move community translation to Weblate, with a status report and machine-drafted starting points #496

Description

@Pixnop

Summary

Translating the launcher today means editing a JSON file of about 660 keys in a pull request, which keeps most players out. Twelve of the fourteen locales are missing between 266 and 504 keys and fall back to English. This moves community translation to Weblate (free hosting for libre projects), keeps developers honest with a missing-keys report in CI, and seeds the lagging locales with machine drafts so translators review instead of starting from nothing.

Why

  • fr-FR is complete and pinned by tests/i18n/i18n-parity.test.ts; the other locales drift with every feature.
  • A translator needs a browser and a GitHub account, not git, JSON and Prettier.
  • Every translation still lands as a pull request on dev reviewed like any other change.

What changes

Weblate (hosted.weblate.org, libre plan)

  • Project RiftLauncher, one component on src/renderer/src/locales/*.json, source en-US.json, format i18next JSON, branch dev, pushes as pull requests through Weblate's GitHub integration, commits in the translator's name.
  • Glossary seeded with the launcher's terms (Mod, Installation, VS Version, modpack, profile, backup, ModDB, launcher) and their fr-FR renderings.
  • Machine suggestions on (DeepL or the service configured on the project), review workflow suggestion then approve.
  • JSON output aligned with Prettier (two-space indentation, key order kept) so format:check stays green on Weblate's pull requests.
  • A link to Weblate in README and on the website, as the libre plan asks.

In the repository

  • npm run i18n:status: missing and stale keys per locale, as a table; a workflow comments it on pull requests that touch en-US.json and refreshes a status page in docs/.
  • The parity test keeps requiring fr-FR for every key; the other locales are reported, not enforced, until they catch up.
  • A "Help translate" link in the language selector (Config) pointing at the Weblate project, through the external-link adapter and the URL allowlist.
  • CONTRIBUTING and the translation guide updated: Weblate first, pull requests still welcome.

Seeding

  • One-time machine drafts for the twelve lagging locales, opened as one pull request per locale, marked as drafts to review, so Weblate starts from a full file.

Out of scope

Reducing the number of keys (a separate cleanup), per-key screenshots (nice to have in Weblate later), holding locales other than fr-FR to the parity test.

Acceptance

  • The Weblate project exists, linked to the repository, and a translation made there arrives as a pull request on dev that passes format:check.
  • npm run i18n:status prints the table and the workflow comments it on a pull request adding an en-US key.
  • The language selector shows the "Help translate" link and it opens the Weblate project.
  • Every locale file has every en-US key after seeding, with the machine-drafted ones listed as to review.
  • README, website and the contribution guide point at Weblate.

Steps

  1. Lead: create the account on hosted.weblate.org with GitHub, create the project, request libre hosting.
  2. Component configuration, glossary, formatting alignment, links and docs.
  3. Status script and workflow.
  4. Seeding pull requests, one per locale.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions