with one click
scaffold
脚手架(/scaffold):空项目创建栈模板,已有项目审计与建议。说「初始化」「创建项目」「脚手架」时用。须用户确认后再创建。
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Menu
脚手架(/scaffold):空项目创建栈模板,已有项目审计与建议。说「初始化」「创建项目」「脚手架」时用。须用户确认后再创建。
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Based on SOC occupation classification
REST/OpenAPI 设计审查。
系统调试循环(/debug)— 复现→假设→隔离→验证→记录;禁止无复现盲改。说「修 bug」「测挂了」「不知道为啥挂」时用。
交付验收(/delivery):视觉 · i18n · 文档对齐 · 后端对接 · 组件完整度 · 可维护性 · 生产就绪。Sprint 收尾或 /release 分支前走查。说「交付验收」「上线前检查」「生产就绪」时用。
磁盘快照(/disk):结构化采集 HOME 与可配置路径占用,写入 .cursorGrowth/disk-snapshots/, 并与上次快照对比变动。说「磁盘快照」「空间变动」「disk snapshot」时也触发。
Git — 分支、提交、合并。需要 git 操作时用。
信息架构(IA)规划与审查(/ia)— 工作流正交、角色入口、分支点、反模式。说「信息架构」「导航迷路」「角色首页」「工作流分支」「Dashboard 太乱」时用。
| name | scaffold |
| description | 脚手架(/scaffold):空项目创建栈模板,已有项目审计与建议。说「初始化」「创建项目」「脚手架」时用。须用户确认后再创建。 |
| disable-model-invocation | true |
模板:.cursor/templates/scaffold/(standard+:lint/test/verify/README + CI + .env.example)· CLI:.cursor/bin/scaffold.sh · 目录见 catalog.md
说明:脚手架是 scaffold skill 驱动的模板文件,不是多个 skill;日常编码细则仍由 rules/tech/*.mdc 按 glob 加载。
闸门:脚手架创建属于用户明确授权的仓库初始化;空仓库(detect → state=empty)可在无 plan.md 时执行。已有代码必须先 audit + AskQuestion 确认,默认 --dry-run,禁止静默覆盖。
/scaffold · 「初始化项目」「创建脚手架」「空仓库怎么开始」/plan 中用户要新建项目 → 在 PLANNING:true 阶段用本 skill 流程提问,确认后 apply 或写入 TASK-001 验收列./.cursor/bin/scaffold.sh detect
./.cursor/bin/scaffold.sh list
| 问题 | 选项示例 |
|---|---|
| 项目类型 | frontend · backend · systems |
| 技术栈 | react-vite-ts · vue-vite-ts · nextjs-ts · go-api · rust-axum · python-fastapi · java-gradle · cpp-cmake |
| 模块路径(Go) | 默认 example.com/app,问用户是否替换 |
| 包管理器 | npm / pnpm(前端);venv(Python) |
./.cursor/bin/scaffold.sh info <id>
./.cursor/bin/scaffold.sh apply <id> --dry-run
用表格列出将 CREATE / SKIP 的文件;说明 post_apply 与 verify。
./.cursor/bin/scaffold.sh apply <id>
post_apply(npm install、go mod tidy 等)./scripts/verify.sh 或更新 config/workflow.json → verify_defaultcp .cursor/templates/plan.md ./plan.md → /plan 拆首个 Sprint(plan.md 已在 .gitignore,不提交)docs/specs/(或 workflow.json sdd.specs_dir)· 模板见 .cursor/templates/sdd/ · /plan §SDD/learn 写入栈与目录约定到 .cursorGrowth/learn/learn/dev-conventions.md 可选install-super-cursor.sh 复制全量母版后,不要假设每个 rules/tech/* 与外网 skill 都该默认加载。
| 步 | 动作 |
|---|---|
| 1 | 读栈证据(见 master routes.md §DAILY/LIBRARY) |
| 2 | DAILY — 匹配栈的 rules/tech/* + 核心 workflow skills(plan · run · learn) |
| 3 | LIBRARY — 离栈 tech rules、偶用 skill(perf · mcp · study 主题);需要时再手动 @ 或 slash |
| 4 | 可选:在 .cursorGrowth/learn/dev-conventions.md 记一行「本仓 DAILY 面」供 plan/run 引用 |
禁止:为裁剪再装 ECC/OpenClaw 等第二套 bundle CLI;母版路径保持 .cursor/ + 可选个人 ~/.cursor/skills/。
每套 standard 脚手架均含:
| 脚本 | 用途 |
|---|---|
scripts/test.sh | 开发中快速回归(仅测试) |
scripts/verify.sh | 任务/Sprint全量验收(lint+test+build 等) |
tests/README.md | 测试目录说明(Java 为 src/test/README.md) |
plan.md 验收列建议:
./scripts/test.sh 或栈内等价(npm run test · go test ./... · pytest)./scripts/verify.shnpm run test:watch · Go go test -v ./tests/... · Python pytest -v tests/unitmanifest 字段 test / verify 见 templates/scaffold/manifest.json。
detect + audit — 不直接 applyscripts/verify.sh / 只给建议--dry-run → 确认 → apply(无 --force 除非用户明确要求覆盖)rules/tech/* 与 /learn| 场景 | 做法 |
|---|---|
| 空仓库先搭架 | /scaffold 确认 → apply → /plan |
| 规划阶段纳入 | Sprint 加 TASK-001 初始化,验收:./.cursor/bin/scaffold.sh apply <id> && ./scripts/verify.sh |
| 仅建议 | SPIKE- 调研选型,结论归档后再 TASK-* |
/run 执行脚手架任务时仍须 gate-check 通过。
apply(尤其 established 仓库)--force 覆盖用户文件.cursor/templates/scaffold/(应走 /learn 或 rules/local/)