feat(cli): cph init / cph add 子命令(工程脚手架)

init 生成可 check 的工程根(manifest.toml + .cph-version + 默认 exports/student.typ + 空 kind 目录);
add 按 kind 建 part 目录/element.toml/必填内容文件并追加 [[parts]]。均纯本地,不涉及 hub 语义;
Engine 改惰性构造。cph-schema 新增 required_content_field_names() 作为 add 建文件合同。
This commit is contained in:
2026-08-05 21:07:50 +08:00
parent 7a0b4b0c4f
commit 5866b3d6cc
6 changed files with 444 additions and 9 deletions
Generated
+1
View File
@@ -411,6 +411,7 @@ dependencies = [
"cph-check",
"cph-diag",
"cph-model",
"cph-schema",
"cph-typst",
"serde_json",
]