ente/.github/workflows/web-crowdin.yml

42 lines
1.5 KiB
YAML
Raw Normal View History

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:
paths:
2024-03-04 10:52:44 +00:00
# Run action when web's en-US/translation.json is changed
- "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_*_*_*
- 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
uses: actions/checkout@v4
2023-03-21 13:34:51 +00:00
- name: Crowdin's action
2024-02-22 06:27:55 +00:00
uses: crowdin/github-action@v1
with:
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
localization_branch_name: crowdin-translations-web
2024-02-22 06:27:55 +00:00
create_pull_request: true
skip_untranslated_strings: true
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"
project_id: 569613
2024-02-22 06:27:55 +00:00
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}