feat: 更新文档以说明工作流可见性要求和 GitHub CLI 使用方法

This commit is contained in:
春河晴
2026-03-13 19:33:36 +09:00
parent ca605eb560
commit e21ea5f9cf
2 changed files with 12 additions and 4 deletions

View File

@@ -56,6 +56,11 @@ Triggers:
- manual dispatch only
Visibility requirement:
- because this workflow uses `workflow_dispatch`, GitHub only exposes it after the workflow file exists on the repository default branch
- in this repository, maintainers should merge the workflow file into `main` before expecting it to appear in the Actions UI or be runnable through `gh workflow run`
Inputs:
- `base_branch`: `main` or `r-dev`
@@ -225,6 +230,7 @@ Effect:
GitHub UI:
- Actions -> `Crowdin Bootstrap Target Translations`
- if it does not appear yet, first make sure the workflow file has already landed on the default branch (`main`)
- choose `main` or `r-dev`
- set `confirm_bootstrap` to `yes-bootstrap-current-target-translations`
@@ -232,7 +238,7 @@ GitHub CLI:
```bash
gh workflow run crowdin-bootstrap.yml \
--ref r-dev \
--ref main \
-f base_branch=r-dev \
-f confirm_bootstrap=yes-bootstrap-current-target-translations
```
@@ -244,12 +250,13 @@ Use this only when seeding Crowdin from already-committed target translations, o
GitHub UI:
- Actions -> `Crowdin Sync`
- if a newly added manual workflow does not appear, confirm that workflow file is already on the default branch
- run the workflow on `main` or `r-dev`
GitHub CLI:
```bash
gh workflow run crowdin-sync.yml --ref r-dev
gh workflow run crowdin-sync.yml --ref main
```
### Inspect workflow runs

View File

@@ -160,13 +160,14 @@ GitHub Actions 中的 [`crowdin-sync.yml`](../.github/workflows/crowdin-sync.yml
- 只能手动触发。
- 会把仓库当前已提交的目标语言文件上传到 Crowdin用来保留历史翻译。
- 不会作为日常 workflow 持续上传 GitHub 中的目标语言改动。
- 这个 workflow 必须先存在于仓库默认分支后,才会在 GitHub 网页端出现,也才能被 `gh workflow run` 调用。
常用命令:
```bash
python scripts/i18n_validate.py
gh workflow run crowdin-sync.yml --ref r-dev
gh workflow run crowdin-bootstrap.yml --ref r-dev -f base_branch=r-dev -f confirm_bootstrap=yes-bootstrap-current-target-translations
gh workflow run crowdin-sync.yml --ref main
gh workflow run crowdin-bootstrap.yml --ref main -f base_branch=r-dev -f confirm_bootstrap=yes-bootstrap-current-target-translations
gh run list --workflow crowdin-sync.yml --limit 5
gh pr list --head l10n_r-dev
```