-
Notifications
You must be signed in to change notification settings - Fork 50
79 lines (65 loc) · 2.13 KB
/
dalamud-loc.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
name: Update Dalamud localization files
concurrency:
group: dalamud-loc-sync
permissions:
pull-requests: write
contents: write
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *'
jobs:
export-loc-files:
name: 'Export localization file'
runs-on: windows-latest
steps:
- name: Checkout Dalamud master
uses: actions/checkout@v4
with:
repository: goatcorp/Dalamud
path: Dalamud
submodules: recursive
- name: Set up .NET 8
uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
- name: Run LocExporter
run: |
cd Dalamud/tools/Dalamud.LocExporter
dotnet run -c Release
- name: Upload loc file artifact
uses: actions/upload-artifact@v4
with:
name: 'Dalamud_Localizable'
if-no-files-found: error
path: 'Dalamud/tools/Dalamud.LocExporter/Dalamud_Localizable.json'
synchronize-with-crowdin:
runs-on: ubuntu-latest
name: Synchronize with Crowdin
needs: export-loc-files
steps:
- name: Checkout assets
uses: actions/checkout@v4
- name: Download loc file artifact
uses: actions/download-artifact@v4
with:
name: 'Dalamud_Localizable'
path: 'loc_for_upload'
- name: Upload to Crowdin
uses: crowdin/github-action@v1
with:
upload_sources: true
upload_translations: false
download_translations: true
# We should put this to true when every language has someone that can approve
export_only_approved: false
push_translations: true
commit_message: 'Update localization'
create_pull_request: true
pull_request_title: 'Update localization'
pull_request_body: 'Update localization with latest translations from crowdin'
config: '.github/crowdin.yml'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }}
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}