Skip to content

Commit 7683e71

Browse files
author
Shengjie Xu
committed
Integrate commands listing from the main program
1 parent fecb263 commit 7683e71

File tree

5 files changed

+35
-1
lines changed

5 files changed

+35
-1
lines changed

.github/workflows/ci.yml

+22-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,18 @@ jobs:
2929
- name: Set up Python
3030
uses: actions/setup-python@v5
3131
with:
32-
python-version: '3.x'
32+
python-version: '>= 3.10'
33+
34+
- name: "Download main program"
35+
id: download_main
36+
uses: robinraju/release-downloader@v1
37+
with:
38+
repository: "PrepPipe/preppipe-python"
39+
tag: "latest-main"
40+
fileName: "preppipe-*-py3-none-any.whl"
41+
tarBall: false
42+
zipBall: false
43+
out-file-path: "."
3344

3445
- name: Install dependencies
3546
run: |
@@ -38,6 +49,16 @@ jobs:
3849
python3 -m pip install mkdocs-material
3950
python3 -m pip install mkdocs-static-i18n[material]
4051
52+
- name: Install main program
53+
run: |
54+
python3 -m pip install $(ls preppipe-*-py3-none-any.whl)
55+
56+
- name: Invoke main program to export documentation
57+
run: |
58+
PREPPIPE_LANGUAGE=zh_cn PREPPIPE_TOOL=cmddocs python3 -m preppipe.pipeline_cmd --namespace=vn --markdown=docs/zh/script/cmddocs.md
59+
PREPPIPE_LANGUAGE=zh_hk PREPPIPE_TOOL=cmddocs python3 -m preppipe.pipeline_cmd --namespace=vn --markdown=docs/zh-Hant/script/cmddocs.md
60+
PREPPIPE_LANGUAGE=en PREPPIPE_TOOL=cmddocs python3 -m preppipe.pipeline_cmd --namespace=vn --markdown=docs/en/script/cmddocs.md
61+
4162
- name: Build site
4263
run: mkdocs build -f mkdocs.yml
4364

docs/en/script/cmddocs.md

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Visual Novel Commands Listing
2+
3+
This file should be overwritten by CI script output.

docs/zh-Hant/script/cmddocs.md

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# 視覺小說命令列表
2+
3+
此文件應被 CI 腳本輸出覆蓋。

docs/zh/script/cmddocs.md

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# 视觉小说命令列表
2+
3+
此文件应被 CI 脚本输出覆盖。

mkdocs.yml

+4
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ plugins:
3030
indexpage: 首页
3131
intro: 简介
3232
frontend: 剧本格式(前端)
33+
frontendcmddocs: 命令列表(自动生成)
3334
middleend: 分析优化工具(中端)
3435
backend: 引擎支持(后端)
3536
- locale: zh-Hant
@@ -39,6 +40,7 @@ plugins:
3940
indexpage: 首頁
4041
intro: 簡介
4142
frontend: 劇本格式(前端)
43+
frontendcmddocs: 命令列表(自動生成)
4244
middleend: 分析優化工具(中端)
4345
backend: 引擎支持(後端)
4446
- locale: en
@@ -48,6 +50,7 @@ plugins:
4850
indexpage: Home
4951
intro: Introduction
5052
frontend: Script Format (Frontend)
53+
frontendcmddocs: Commands Listing (Auto-generated)
5154
middleend: Analysis and Opt Tools (Middleend)
5255
backend: Engine Support (Backend)
5356
- privacy
@@ -67,6 +70,7 @@ nav:
6770
- "intro/functionality.md"
6871
- frontend:
6972
- "script/overview.md"
73+
- frontendcmddocs: "script/cmddocs.md"
7074
- middleend:
7175
- "middleend/overview.md"
7276
- "middleend/assetusage.md"

0 commit comments

Comments
 (0)