-
Notifications
You must be signed in to change notification settings - Fork 2
55 lines (44 loc) · 1.49 KB
/
sync-translatable-strings.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: Sync translations with Crowdin
on:
push:
branches:
- 'master'
paths:
- 'sources/**'
- '!sources/backend/**'
schedule:
- cron: '00 00 * * 1'
workflow_dispatch:
jobs:
sync_translatable_strings:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Update translatable strings
run: docker run --rm -v $(pwd):/workspace ghcr.io/linuxmuster/linuxmuster-linbo-gui-build linbo-gui-lupdate
- name: Delete all but blank.ts
run: |
rm ./resources/translations/linbo-gui/*-*.ts
- name: Sync translations with crowdin
uses: crowdin/github-action@1.0.16
with:
token: ${{ secrets.CROWDIN_API_TOKEN }}
# upload translation template
upload_sources: true
# download new translations
download_translations: true
skip_untranslated_strings: true
export_only_approved: true
push_translations: false
- name: Create en-GB.ts
run: |
cp ./resources/translations/linbo-gui/blank.ts ./resources/translations/linbo-gui/en-GB.ts
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
with:
commit-message: "New Translations from Crowdin (by GitHub Action)"
title: "New Translations from Crowdin (by GitHub Action)"
body: "New Translations from Crowdin (by GitHub Action)"
author: "GitHub Action <action@github.com>"
branch: "i18n"