-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1370 from karaoke-dev/test-upload-localization
Trigger the upload localization string.
- Loading branch information
Showing
1 changed file
with
15 additions
and
11 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,20 +19,24 @@ jobs: | |
- name: Install the localization tools. | ||
run: dotnet tool restore | ||
- name: Generate the localization file | ||
run: dotnet localisation to-resx ./osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj --output ${{github.workspace}}\crowdin | ||
run: dotnet localisation to-resx ./osu.Game.Rulesets.Karaoke/osu.Game.Rulesets.Karaoke.csproj --output ./crowdin | ||
|
||
synchronize-with-crowdin: | ||
name: Upload the localization into crowdin | ||
runs-on: ubuntu-latest | ||
needs: [generate-localization-file] | ||
steps: | ||
- name: crowdin action | ||
- name: Upload the localization into crowdin | ||
uses: crowdin/[email protected] | ||
with: | ||
upload_translations: true | ||
download_translations: false | ||
source: ${{github.workspace}}\crowdin\*.resx | ||
translation: ${{github.workspace}}\crowdin\%file_name%.%locale%.%file_extension% | ||
# upload the source to the target path of the https://github.com/karaoke-dev/karaoke-resources | ||
# see the document in the https://support.crowdin.com/configuration-file/?q=dest | ||
upload_sources: true | ||
upload_sources_args: '--dest master/osu.Game.Rulesets.Karaoke.Resources/Localisation/%file_name%.%file_extension%' | ||
source: crowdin/*.resx | ||
# there's no translation can be uploaded in this repo, but we still need to give it a value. | ||
translation: crowdin/%file_name%.%locale%.%file_extension% | ||
# This is a numeric id, not to be confused with Crowdin API v1 "project identifier" string. | ||
# See "API v2" on https://crowdin.com/project/<your-project>/settings#api | ||
project_id: ${{ secrets.CROWDIN_PROJECT_ID }} | ||
# A personal access token, not to be confused with Crowdin API v1 "API key". | ||
# See https://crowdin.com/settings#api-key to generate a token. | ||
token: ${{ secrets.CROWDIN_PERSONAL_TOKEN }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }} | ||
|