Internationalisation: Move some config to crowdin.yml to upload multiple files (#105480)
* move some config to crowdin.yml to upload multiple files * explicitly add the type * different dest for plugins * better dest
This commit is contained in:
@@ -5,6 +5,7 @@ on:
|
||||
push:
|
||||
paths:
|
||||
- 'public/locales/en-US/grafana.json'
|
||||
- 'public/app/plugins/datasource/azuremonitor/locales/en-US/grafana-azure-monitor-datasource.json'
|
||||
branches:
|
||||
- main
|
||||
|
||||
@@ -35,14 +36,11 @@ jobs:
|
||||
uses: crowdin/github-action@b8012bd5491b8aa8578b73ab5b5f5e7c94aaa6e2
|
||||
with:
|
||||
upload_sources: true
|
||||
upload_sources_args: '--dest=public/locales/en-US/grafana.json'
|
||||
upload_translations: false
|
||||
download_translations: false
|
||||
create_pull_request: false
|
||||
base_url: 'https://grafana.api.crowdin.com'
|
||||
config: 'crowdin.yml'
|
||||
source: 'public/locales/en-US/grafana.json'
|
||||
translation: 'public/locales/%locale%/%original_file_name%'
|
||||
env:
|
||||
CROWDIN_PROJECT_ID: 5
|
||||
CROWDIN_PERSONAL_TOKEN: ${{ env.CROWDIN_TOKEN }}
|
||||
|
||||
+15
-2
@@ -1,5 +1,18 @@
|
||||
files:
|
||||
- type: i18next_json
|
||||
# The following are pulled from env variables
|
||||
project_id_env: CROWDIN_PROJECT_ID
|
||||
api_token_env: CROWDIN_PERSONAL_TOKEN
|
||||
|
||||
preserve_hierarchy: true
|
||||
files: [
|
||||
{
|
||||
"source": "public/locales/en-US/grafana.json",
|
||||
"translation": "public/locales/%locale%/%original_file_name%",
|
||||
"type": "i18next_json",
|
||||
},
|
||||
{
|
||||
"source": "public/app/plugins/datasource/azuremonitor/locales/en-US/grafana-azure-monitor-datasource.json",
|
||||
"translation": "public/app/plugins/datasource/azuremonitor/locales/%locale%/%original_file_name%",
|
||||
"type": "i18next_json",
|
||||
"dest": "plugins/azuremonitor/en-US/%original_file_name%"
|
||||
},
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user