Crowdin Download #74
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Crowdin Download | |
on: | |
schedule: | |
- cron: '0 0 * * 0' | |
workflow_dispatch: | |
permissions: | |
contents: write | |
pull-requests: write | |
jobs: | |
synchronize-with-crowdin: | |
name: Download translations from Crowdin | |
if: github.repository_owner == 'Mahmud0808' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Generate contributors table | |
id: "contributors" | |
uses: andrii-bodnar/action-crowdin-contributors@v2 | |
with: | |
contributors_per_line: 6 | |
max_contributors: 500 | |
image_size: 32 | |
min_words_contributed: 1 | |
files: ./docs/contributors.md | |
env: | |
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }} | |
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }} | |
- name: Save contributors in assets | |
run: | |
printf '%s\n' '${{ steps.contributors.outputs.json_report }}' > ./app/src/main/assets/Misc/contributors.json | |
- name: Download translations | |
uses: crowdin/github-action@v2 | |
with: | |
upload_translations: false | |
upload_sources: false | |
download_translations: true | |
localization_branch_name: beta-localization | |
create_pull_request: true | |
env: | |
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} | |
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }} | |
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }} |