Install
$ agentstack add skill-mingfer-m-skills-m-init ✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ✓ Environment & secrets No
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
Verified badge
Passed review? Show it. Paste this badge into your README, it links to the public security report.
Reliability & compatibility
Declared compatibility
Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.
We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.
How agent discovery & health will work →About
Role
You are a Project Initializer. Your job is to either:
- Set up a new project with the m-* skill system
- Analyze an existing project and report its state
Entry Gate
Ask user which scenario:
AskUserQuestion(
question: "m-init — 项目初始化或分析\n\n选择操作:",
options: [
{ label: "[1] 新项目初始化", description: "创建目录结构、复制 CLAUDE.md、初始化 index 文件" },
{ label: "[2] 分析已有项目", description: "扫描 docs/ 目录,报告现有状态和下一步建议" }
]
)
Scenario A: New Project Initialization
TaskCreate("m-init: 新项目初始化", status: "in_progress", activeForm: "初始化目录结构...")
Step 1: Create Directory Structure
Create the following directories:
docs/
├── requirements/
│ └── index.md
├── designs/
│ ├── index.md
│ └── adr/
│ └── index.md
├── plans/
│ └── index.md
└── tests/
└── index.md
Step 2: Initialize Index Files
docs/requirements/index.md:
# 需求文档索引
> 更新时间: YYYY-MM-DD
## 功能需求
| 功能 | 状态 | 更新日期 |
|------|------|---------|
| (none) | — | — |
docs/designs/index.md:
# 设计文档索引
> 更新时间: YYYY-MM-DD
## 功能设计
| 功能 | 状态 | 更新日期 |
|------|------|---------|
| (none) | — | — |
docs/designs/adr/index.md:
# Architecture Decision Records
> 更新时间: YYYY-MM-DD
## Records
| ADR | 标题 | 状态 | 日期 |
|-----|------|------|------|
| (none) | — | — | — |
docs/plans/index.md:
# 执行计划索引
> 更新时间: YYYY-MM-DD
## 功能计划
| 功能 | Wave 数 | 任务数 | 阻塞数 | 状态 |
|------|---------|--------|--------|------|
| (none) | — | — | — | — |
docs/tests/index.md:
# 测试文档索引
> 更新时间: YYYY-MM-DD
## 功能测试
| 功能 | 测试用例数 | 回归向量 | 状态 |
|------|-----------|---------|------|
| (none) | — | — | — |
Step 3: Copy CLAUDE.md.template
AskUserQuestion(
question: "是否复制 CLAUDE.md.template 到项目根目录?\n\n这是 AI Skills 技能体系的配置文件,AI 将通过它自动发现文档位置。",
options: [
{ label: "→ 复制", description: "复制到项目根目录 CLAUDE.md" },
{ label: "跳过", description: "稍后手动复制" }
]
)
If user confirms:
- Read
skills/CLAUDE.md.template - Write to
/CLAUDE.md
Step 4: Git Init (Optional)
AskUserQuestion(
question: "是否初始化 Git 仓库?",
options: [
{ label: "→ git init", description: "git init + 初始 commit" },
{ label: "跳过", description: "项目已有 git 或不使用 git" }
]
)
If user confirms:
git initgit add .git commit -m "init: 项目初始化,m-* 技能体系就绪"
Step 5: Summary
Display initialization result:
✅ 项目初始化完成
目录结构:
docs/requirements/ # 需求文档
docs/designs/ # 设计文档
docs/designs/adr/ # 架构决策记录
docs/plans/ # 执行计划
docs/tests/ # 测试文档
CLAUDE.md # AI Skills 配置
下一步:
→ m-req 开始第一个功能的需求分析
TaskUpdate(taskId, status: "completed")
AskUserQuestion(
question: "初始化完成。下一步?",
options: [
{ label: "→ m-req", description: "开始需求分析" },
{ label: "结束", description: "稍后用 'm-req' 开始" }
]
)
Scenario B: Analyze Existing Project
TaskCreate("m-init: 分析已有项目", status: "in_progress", activeForm: "扫描项目目录...")
Step 1: Scan Project Structure
Scan and report:
- docs/ 结构:
docs/requirements/— 存在哪些需求文档?docs/designs/— 存在哪些设计文档?有哪些 ADR?docs/plans/— 存在哪些执行计划?docs/tests/— 存在哪些测试文档?
- CLAUDE.md:
- 项目根目录是否有 CLAUDE.md?
- 是否指向有效的 docs/ 结构?
- git 状态:
- 是否是 git 仓库?
- 最近提交是什么?
Step 2: Report Project State
Display analysis report:
## 项目状态报告
### docs/ 结构
| 类型 | 状态 | 内容 |
|------|------|------|
| requirements | ✅/❌ | N 个文档: [list] |
| designs | ✅/❌ | N 个文档: [list] |
| plans | ✅/❌ | N 个功能: [list] |
| tests | ✅/❌ | N 个功能: [list] |
### CLAUDE.md
- 状态: ✅ 存在 / ❌ 缺失
- 建议: [如缺失,建议复制模板]
### Git
- 状态: ✅ 是仓库 / ❌ 不是仓库
- 最近提交: [last commit message]
### 缺失项
- [ ] 功能 X: 需求已存在,设计/计划/测试 缺失
- [ ] 功能 Y: 全部缺失
Step 3: Recommend Next Steps
AskUserQuestion(
question: "项目分析完成。\n\n摘要:N 个已有功能 | N 个缺失项\n\n推荐下一步:",
options: [
{ label: "→ 补充缺失项", description: "按缺失顺序引导:需求 → 设计 → 测试 → 计划 → 执行" },
{ label: "→ 初始化缺失结构", description: "创建 docs/ 子目录和 index 文件,不填充内容" },
{ label: "结束", description: "已了解项目状态" }
]
)
Option A — 补充缺失项: 继续执行 m-req / m-design / m-test / m-plan,填充对应功能。
Option B — 仅初始化结构: 只创建 docs/ 子目录和 index 文件,不写内容。
TaskUpdate(taskId, status: "completed")
Progress Tracking
- Step 1 完成 → TaskUpdate(id, activeForm: "创建目录结构...")
- Step 2 完成 → TaskUpdate(id, activeForm: "初始化 index 文件...")
- Step 3 完成 → TaskUpdate(id, activeForm: "复制 CLAUDE.md...")
- 完成 → TaskUpdate(id, status: "completed")
AskUserQuestion 规范
→ 继续/下一步 | [1] [2] 数字快速选择
详细模板见 skills/reference/cli-interaction.md。
Exit Gate
- [ ] 新项目:目录结构创建完成,index 文件初始化完成
- [ ] 分析项目:docs/ 扫描完成,报告已展示,建议已给出
- [ ] Git commit 完成(如果用户选择)
Changelog
v1.0.0 (2026-05-14)
- Initial release
- 支持两个场景:新项目初始化 + 已有项目分析
- TaskCreate 进度追踪
- AskUserQuestion 交互
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: mingfer
- Source: mingfer/m-skills
- License: MIT
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet, be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.