Skip to content

feat: Reintroduce crowdin synchronization. #4122

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 17 commits into
base: main
Choose a base branch
from
Open

Conversation

IMB11
Copy link
Member

@IMB11 IMB11 commented Aug 5, 2025

This is a continuation of @brawaru's previous pull request before the monorepo (modrinth/knossos#1640) with the main change being it only runs on the main branch, rather than using Crowdin's branching functionality to have multiple branches of sources, which we wouldn't use anymore.

Thank you @brawaru!


Prerequisites

  • Delete all sources from the Crowdin project (whilst keeping the translation memory!)
  • Make sure there are no github-related integrations in the integrations tab.
  • Create a fine-grained access token for the "Modrinth Bot" github account with the following permissions, placing it in the CROWDIN_GH_TOKEN repository environment secret;
    • contents: write
    • pull-requests: write
  • Copy the https://crowdin.com/project/modrinth project ID into the CROWDIN_PROJECT_ID repository variable.
  • Create an access token on the "Modrinth" crowdin account with all scopes, and place the token into CROWDIN_PERSONAL_TOKEN repo secret.
  • Modify the pull request description template in .github as needed (probably wont need any changes honestly)
  • Merge the PR.
  • The push workflow should run and push the new sources to Crowdin.
  • (optional) Pre-translate using translation memory.

The first pull request made by the CI will be large as it has to populate the initial locale files with {}, after that it should be pretty small and review-able.

@IMB11 IMB11 added frontend DevEx Improvements to developer experience labels Aug 5, 2025
@IMB11
Copy link
Member Author

IMB11 commented Aug 5, 2025

After #4025 is merged, we can add it to the crowdin.yml for the moderation package. Can be done in a different PR though.

@brawaru
Copy link
Contributor

brawaru commented Aug 5, 2025

If you manually move the existing files on Crowdin to expected locations before first running this workflow, you won't have to lose any translations and force translators to restore translations by hand from translation memory! :)

That is,

  1. Rename [modrinth.knossos] master to [modrinth.code] main
  2. Create web subfolder under [modrinth.code] main
  3. Select all files in the root of [modrinth.code] main and move them to web
  4. Create ui subfolder under [modrinth.code] main
  5. Drag index.json from [modrinth.omorphia] master to that ui folder

@IMB11 IMB11 requested a review from Prospector August 5, 2025 16:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DevEx Improvements to developer experience frontend
Development

Successfully merging this pull request may close these issues.

2 participants