2024-03-04 06:05:42 +00:00
|
|
|
name: "Sync Crowdin translations (web)"
|
2023-03-21 13:34:51 +00:00
|
|
|
|
|
|
|
on:
|
2024-02-22 06:27:55 +00:00
|
|
|
push:
|
2024-03-04 05:31:27 +00:00
|
|
|
paths:
|
2024-03-04 10:52:44 +00:00
|
|
|
# Run action when web's en-US/translation.json is changed
|
2024-03-04 05:31:27 +00:00
|
|
|
- "web/apps/photos/public/locales/en-US/translation.json"
|
2024-03-04 10:52:44 +00:00
|
|
|
# Or the workflow itself is changed
|
|
|
|
- ".github/workflows/web-crowdin.yml"
|
2024-02-22 06:27:55 +00:00
|
|
|
branches: [main]
|
|
|
|
schedule:
|
2024-03-04 06:05:42 +00:00
|
|
|
# Run every 24 hours - https://crontab.guru/#0_*/24_*_*_*
|
2024-03-04 05:31:27 +00:00
|
|
|
- cron: "0 */24 * * *"
|
2024-03-04 06:05:42 +00:00
|
|
|
workflow_dispatch: # Allow manually running the action
|
2023-03-21 13:34:51 +00:00
|
|
|
|
|
|
|
jobs:
|
2024-02-22 06:27:55 +00:00
|
|
|
synchronize-with-crowdin:
|
|
|
|
runs-on: ubuntu-latest
|
2023-03-21 13:34:51 +00:00
|
|
|
|
2024-02-22 06:27:55 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2024-03-04 05:31:27 +00:00
|
|
|
uses: actions/checkout@v4
|
2023-03-21 13:34:51 +00:00
|
|
|
|
2024-03-04 05:31:27 +00:00
|
|
|
- name: Crowdin's action
|
2024-02-22 06:27:55 +00:00
|
|
|
uses: crowdin/github-action@v1
|
|
|
|
with:
|
2024-03-04 06:30:42 +00:00
|
|
|
base_path: "web/"
|
2024-03-04 10:52:44 +00:00
|
|
|
config: "web/crowdin.yml"
|
2024-02-22 06:27:55 +00:00
|
|
|
upload_sources: true
|
|
|
|
upload_translations: true
|
|
|
|
download_translations: true
|
2024-03-04 05:31:27 +00:00
|
|
|
localization_branch_name: crowdin-translations-web
|
2024-02-22 06:27:55 +00:00
|
|
|
create_pull_request: true
|
|
|
|
skip_untranslated_strings: true
|
2024-03-06 05:18:27 +00:00
|
|
|
pull_request_title: "[web] New translations"
|
|
|
|
pull_request_body: "New translations from [Crowdin](https://crowdin.com/project/ente-photos-web)"
|
2024-02-22 06:27:55 +00:00
|
|
|
pull_request_base_branch_name: "main"
|
2024-03-04 07:20:42 +00:00
|
|
|
project_id: 569613
|
2024-02-22 06:27:55 +00:00
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
|