Skip to content

Commit 7b49987

Browse files
authored
ja translaton: support specifying files in translation cron (#22726)
1 parent ea7e897 commit 7b49987

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

.github/workflows/translation-cron.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ on:
55
# every Wednesday at 11:00 AM
66
- cron: "0 11 * * 3"
77
workflow_dispatch:
8+
inputs:
9+
file_names:
10+
description: 'Specify file names to translate (comma-separated list)'
11+
required: false
12+
type: string
13+
default: ''
814

915
env:
1016
LTS_BRANCH: i18n-ja-release-8.5
@@ -24,7 +30,7 @@ jobs:
2430
-H "Accept: application/vnd.github+json" \
2531
-H "Authorization: token ${{ github.token }}" \
2632
https://api.github.com/repos/${{ github.repository }}/actions/workflows/translation-zh.yaml/dispatches \
27-
-d '{"ref":"master"}'
33+
-d '{"ref":"master","inputs":{"file_names":${{ toJSON(inputs.file_names || '') }}}}'
2834
2935
# build a matrix of branches to translate, including LTS and Cloud
3036
build-matrix:
@@ -75,6 +81,7 @@ jobs:
7581
with:
7682
config_file: latest_translation_commit.json
7783
working_directory: docs
84+
files: ${{ inputs.file_names || '' }}
7885

7986
- name: Show tmp directory structure
8087
run: |

0 commit comments

Comments
 (0)