Skip to content
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

Setup Crowdin #52

Merged
merged 2 commits into from Jul 19, 2022
Merged

Setup Crowdin #52

merged 2 commits into from Jul 19, 2022

Conversation

andrii-bodnar
Copy link
Contributor

Hey everyone,

I'm suggesting the integration with Crowdin via GitHub Actions. Crowdin is free for open-source projects. This integration works in the following way:

  • the action runs every 6 hours (actually, it's up to you what trigger to use, it could also be a push to the default branch, for example)
  • upload new source texts to the Crowdin project
  • upload existing translations to Crowdin (using the upload_translations action config parameter, it's necessary only for the first time)
  • download all the new translations from Crowdin and commit these translations to the localization_branch_name
  • open a Pull Request with the latest translations.

You can find my demo Crowdin project here - classicpowermenu-demo.

Example of the first PR that will be created by Crowdin Action - https://github.com/andrii-bodnar/ClassicPowerMenu/pull/1 (Don't worry about the diffs - it's only the first time, in the next PRs diffs will include only the latest translations from Crowdin).

Fixes #51

@andrii-bodnar
Copy link
Contributor Author

The next steps we can do to move further with this integration:

  • Create a Crowdin account.
  • Submit the Open-source project setup request form.
  • Create a new Crowdin Project:
    • Fill in other target languages.
    • In the project settings enable the global Translation Memory (optional).
  • Generate a new Personal Access Token in your Crowdin account settings.
  • Generate a new GitHub Token (only the repo scope is required).
  • Create the Actions secrets for your repository:
    • CROWDIN_PERSONAL_TOKEN - the personal access token generated in Crowdin.
    • CROWDIN_PROJECT_ID - ID of the Crowdin project.
    • GH_TOKEN - the personal access token generated in GitHub.
  • merge this PR.

@andrii-bodnar
Copy link
Contributor Author

Hi @KieronQuinn, could you please check this PR? 🙂

@KieronQuinn
Copy link
Owner

It looks fine, but the whole repo is a mess to the point I actually can't build the app properly anymore. Something dependency related, I don't have time to fix it. To do builds I currently have to run a combination of console gradle commands and generate signed APK - so I can't do big changes like this. I will sort this eventually.

@KieronQuinn
Copy link
Owner

Update on this, I've solved the dependency issue and have followed all the steps. Merging now.

@KieronQuinn KieronQuinn merged commit 7e61367 into KieronQuinn:main Jul 19, 2022
@KieronQuinn
Copy link
Owner

Seems to have worked, thanks so much for your help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Crowdin Translations
2 participants