feat: 更新文档以说明工作流可见性要求和 GitHub CLI 使用方法
This commit is contained in:
@@ -56,6 +56,11 @@ Triggers:
|
|||||||
|
|
||||||
- manual dispatch only
|
- 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:
|
Inputs:
|
||||||
|
|
||||||
- `base_branch`: `main` or `r-dev`
|
- `base_branch`: `main` or `r-dev`
|
||||||
@@ -225,6 +230,7 @@ Effect:
|
|||||||
GitHub UI:
|
GitHub UI:
|
||||||
|
|
||||||
- Actions -> `Crowdin Bootstrap Target Translations`
|
- 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`
|
- choose `main` or `r-dev`
|
||||||
- set `confirm_bootstrap` to `yes-bootstrap-current-target-translations`
|
- set `confirm_bootstrap` to `yes-bootstrap-current-target-translations`
|
||||||
|
|
||||||
@@ -232,7 +238,7 @@ GitHub CLI:
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
gh workflow run crowdin-bootstrap.yml \
|
gh workflow run crowdin-bootstrap.yml \
|
||||||
--ref r-dev \
|
--ref main \
|
||||||
-f base_branch=r-dev \
|
-f base_branch=r-dev \
|
||||||
-f confirm_bootstrap=yes-bootstrap-current-target-translations
|
-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:
|
GitHub UI:
|
||||||
|
|
||||||
- Actions -> `Crowdin Sync`
|
- 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`
|
- run the workflow on `main` or `r-dev`
|
||||||
|
|
||||||
GitHub CLI:
|
GitHub CLI:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
gh workflow run crowdin-sync.yml --ref r-dev
|
gh workflow run crowdin-sync.yml --ref main
|
||||||
```
|
```
|
||||||
|
|
||||||
### Inspect workflow runs
|
### Inspect workflow runs
|
||||||
|
|||||||
@@ -160,13 +160,14 @@ GitHub Actions 中的 [`crowdin-sync.yml`](../.github/workflows/crowdin-sync.yml
|
|||||||
- 只能手动触发。
|
- 只能手动触发。
|
||||||
- 会把仓库当前已提交的目标语言文件上传到 Crowdin,用来保留历史翻译。
|
- 会把仓库当前已提交的目标语言文件上传到 Crowdin,用来保留历史翻译。
|
||||||
- 不会作为日常 workflow 持续上传 GitHub 中的目标语言改动。
|
- 不会作为日常 workflow 持续上传 GitHub 中的目标语言改动。
|
||||||
|
- 这个 workflow 必须先存在于仓库默认分支后,才会在 GitHub 网页端出现,也才能被 `gh workflow run` 调用。
|
||||||
|
|
||||||
常用命令:
|
常用命令:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
python scripts/i18n_validate.py
|
python scripts/i18n_validate.py
|
||||||
gh workflow run crowdin-sync.yml --ref r-dev
|
gh workflow run crowdin-sync.yml --ref main
|
||||||
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-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 run list --workflow crowdin-sync.yml --limit 5
|
||||||
gh pr list --head l10n_r-dev
|
gh pr list --head l10n_r-dev
|
||||||
```
|
```
|
||||||
|
|||||||
Reference in New Issue
Block a user