customaize-agent%3Acreate-command by neolabhq/context-engineering-kit
npx skills add https://github.com/neolabhq/context-engineering-kit --skill customaize-agent:create-command包含 Shell 命令
此技能包含可能执行系统命令的 shell 命令指令(!命令``)。安装前请仔细审查。
此元命令通过以下方式帮助创建其他命令:
<command_categories>
* 功能构思、提案、PRD
* 具有不同阶段的复杂工作流
* 交互式、对话式风格
* 创建文档工件
* 示例:@/.claude/commands/01_brainstorm-feature.md @/.claude/commands/02_feature-proposal.md
2. 实现命令(通用,带模式)
* 技术执行任务
* 基于模式的变体(ui、core、mcp 等)
* 遵循既定模式
* 更新任务状态
* 示例:@/.claude/commands/implement.md
3. 分析命令(专用)
* 审查、审计、分析
* 生成报告或见解
* 读取密集型操作
* 提供建议
* 示例:@/.claude/commands/review.md
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
4. 工作流命令(专用)
* 编排多个步骤
* 协调不同领域
* 管理依赖关系
* 跟踪进度
* 示例:@/.claude/commands/04_feature-planning.md
5. 实用程序命令(通用或专用)
* 工具、助手、维护
* 简单操作
* 可能需要也可能不需要模式 </command_categories>
<command_frontmatter>
所有命令文件必须以 YAML frontmatter 开头,并用 --- 分隔符包围:
---
description: 命令功能的简要描述
argument-hint: 预期参数的描述(可选)
---
description(必需): * 命令用途的单行摘要
* 清晰、简洁、面向行动
* 示例:"通过代码库理解和架构重点进行引导式功能开发"
2. argument-hint(可选):
* 描述命令接受的参数
* 示例:
* "可选功能描述"
* "要分析的文件路径"
* "组件名称和位置"
* "无需参数 - 交互模式"
# 规划命令
---
description: 针对新功能想法的交互式头脑风暴会议
argument-hint: 可选初始功能概念
---
# 实现命令
---
description: 使用基于模式的模式(ui、core、mcp)实现功能
argument-hint: 模式和功能描述(例如,'ui:添加深色模式切换')
---
# 分析命令
---
description: 包含质量评估的全面代码审查
argument-hint: 要审查的可选文件或目录路径
---
# 实用程序命令
---
description: 根据 OpenAPI 标准验证 API 文档
argument-hint: OpenAPI 规范文件的路径
---
--- 之前不能有空行--- 之后,内容开始之前有一个空行 </command_frontmatter><command_features>
使用子目录对相关命令进行分组。子目录会出现在命令描述中,但不影响命令名称。
示例:
.claude/commands/frontend/component.md 创建 /component,描述为"(project:frontend)"~/.claude/commands/component.md 创建 /component,描述为"(user)"优先级: 如果项目命令和用户命令共享相同名称,则项目命令优先。
$ARGUMENTS 捕获所有参数捕获传递给命令的所有参数:
# 命令定义
echo 'Fix issue #$ARGUMENTS following our coding standards' > .claude/commands/fix-issue.md
# 用法
> /fix-issue 123 high-priority
# $ARGUMENTS 变为:"123 high-priority"
$1、$2 等处理单个参数使用位置参数单独访问特定参数:
# 命令定义
echo 'Review PR #$1 with priority $2 and assign to $3' > .claude/commands/review-pr.md
# 用法
> /review-pr 456 high alice
# $1 变为 "456",$2 变为 "high",$3 变为 "alice"
在斜杠命令运行之前,使用 ! 前缀执行 bash 命令。输出将包含在命令上下文中。
注意: 您必须在 allowed-tools 中包含 Bash 工具。
---
allowed-tools: Bash(git add:*), Bash(git status:*), Bash(git commit:*)
description: 创建一个 git 提交
---
## 上下文
- 当前 git 状态:!`git status`
- 当前 git diff:!`git diff HEAD`
- 当前分支:!`git branch --show-current`
- 最近的提交:!`git log --oneline -10`
使用 @ 前缀引用文件以包含文件内容:
Review the implementation in @src/utils/helpers.js
Compare @src/old-version.js with @src/new-version.js
斜杠命令可以通过包含扩展思考关键字来触发扩展思考。
| Frontmatter | 用途 | 默认值 |
|---|---|---|
allowed-tools | 命令可以使用的工具列表 | 从对话继承 |
argument-hint | 用于自动补全的预期参数 | 无 |
description | 命令的简要描述 | 提示的第一行 |
model | 特定模型字符串 | 从对话继承 |
disable-model-invocation | 防止 Skill 工具调用此命令 | false |
包含所有 frontmatter 选项的示例:
---
allowed-tools: Bash(git add:*), Bash(git status:*), Bash(git commit:*)
argument-hint: [message]
description: 创建一个 git 提交
model: claude-3-5-haiku-20241022
---
Create a git commit with message: $ARGUMENTS
</command_features>
<pattern_research>
列出目标目录中的现有命令:
ls -la /.claude/commands/
# 对于用户命令
ls -la ~/.claude/commands/
2. 阅读类似命令以了解模式:
* 检查 frontmatter(描述和 argument-hint)
* 它们如何构建章节?
* 它们使用哪些 MCP 工具?
* 它们如何处理参数?
* 它们引用了哪些文档?
3. 要寻找的常见模式:
# 用于任务的 MCP 工具使用
Use tool: mcp__scopecraft-cmd__task_create
Use tool: mcp__scopecraft-cmd__task_update
Use tool: mcp__scopecraft-cmd__task_list
# 不是 CLI 命令
❌ Run: scopecraft task list
✅ Use tool: mcp__scopecraft-cmd__task_list
4. 要包含的标准引用:
* @/docs/organizational-structure-guide.md
* @/docs/command-resources/{relevant-templates}
* @/docs/claude-commands-guide.md </pattern_research>
<interview_process>
"让我们创建一个新命令。首先,让我检查一下存在哪些类似的命令..."
使用 Glob 查找目标类别中的现有命令
"根据现有模式,请描述:"
根据响应和现有示例:
首先研究类似命令:
# 读取一个类似的命令
@{similar-command-path}
# 注意模式:
- 任务描述风格
- 参数处理
- MCP 工具使用
- 文档引用
- 人工审查部分
🎯 关键决策:这个命令应该放在哪里?
项目命令(/.claude/commands/)
用户命令(~/.claude/commands/)
询问:"这应该是:
检查现有资源:
# 检查模板
ls -la /docs/command-resources/planning-templates/
ls -la /docs/command-resources/implement-modes/
# 检查存在哪些指南
ls -la /docs/
</interview_process>
<generation_patterns>
生成前,阅读类似命令并注意:
Frontmatter(必须是第一个):
description: 命令用途的清晰单行描述
argument-hint: 它接受哪些参数
---
* 开头 `---` 之前不能有空行
* 结尾 `---` 之后有一个空行
* `description` 是必需的
* `argument-hint` 是可选的
2. MCP 工具使用:
# 来自现有命令
Use mcp__scopecraft-cmd__task_create
Use mcp__scopecraft-cmd__feature_get
Use mcp__scopecraft-cmd__phase_list
3. 标准引用:
<context>
Key Reference: @/docs/organizational-structure-guide.md
Template: @/docs/command-resources/planning-templates/{template}.md
Guide: @/docs/claude-commands-guide.md
</context>
4. 任务更新模式:
<task_updates>
After implementation:
1. Update task status to appropriate state
2. Add implementation log entries
3. Mark checklist items as complete
4. Document any decisions made
</task_updates>
5. 人工审查部分:
<human_review_needed>
Flag decisions needing verification:
- [ ] Assumptions about workflows
- [ ] Technical approach choices
- [ ] Pattern-based suggestions
</human_review_needed>
</generation_patterns>
<implementation_steps>
* 根据项目/用户选择确定位置
* 按照既定模式生成内容
* 包含所有必需部分
2. 创建支持文件(如果是项目命令)
* 在 `/docs/command-resources/` 中的模板
* 如果是通用命令,则提供模式指南
* 示例文档
3. 更新文档(如果是项目命令)
* 添加到 claude-commands-guide.md
* 如果是工作流命令,则更新 feature-development-workflow.md
* 如果是面向用户的,则添加到 README
4. 测试命令
* 创建示例使用场景
* 验证参数处理
* 检查 MCP 工具集成 </implementation_steps>
<creation_checklist> 最终确定前:
--- 之前不能有空行)<example_session> 用户:"我需要一个命令来帮助验证我们的 API 文档"
🔍 研究:让我检查现有的分析命令...
使用 Read 工具检查:/.claude/commands/review.md
我注意到 review 命令:
🤔 问题:你能告诉我更多关于这个 API 文档验证的信息吗?
用户:"是 OpenAPI 规范,需要检查完整性和一致性"
💡 类别:这是一个类似于 'review' 的分析命令。
🔍 模式检查:查看 review.md,我看到:
<task>
You are a code reviewer conducting a comprehensive review...
</task>
<mcp_usage>
Always use MCP tools:
- mcp__scopecraft-cmd__task_list
- mcp__scopecraft-cmd__task_update
</mcp_usage>
🎯 位置问题:这应该是:
用户:"项目命令 - 它需要引用我们特定的 API 标准"
✅ 创建项目命令:/.claude/commands/validate-api.md
生成的命令(遵循 review.md 模式):
---
description: 根据 OpenAPI 标准验证 API 文档的完整性和一致性
argument-hint: OpenAPI 规范文件的路径(可选,如果未提供则搜索)
---
<task>
You are an API documentation validator reviewing OpenAPI specifications for completeness and consistency.
</task>
<context>
References:
- API Standards: @/docs/api-standards.md
- Organizational Structure: @/docs/organizational-structure-guide.md
Similar to: @/.claude/commands/review.md
</context>
<validation_process>
1. Load OpenAPI spec files
2. Check required endpoints documented
3. Validate response schemas
4. Verify authentication documented
5. Check for missing examples
</validation_process>
<mcp_usage>
If issues found, create tasks:
- Use tool: mcp__scopecraft-cmd__task_create
- Type: "bug" or "documentation"
- Phase: Current active phase
- Area: "docs" or "api"
</mcp_usage>
<human_review_needed>
Flag for manual review:
- [ ] Breaking changes detected
- [ ] Security implications unclear
- [ ] Business logic assumptions
</human_review_needed>
</example_session>
<final_output> 收集所有信息后:
* 位置:{选定位置}
* 名称:{命令名称}
* 类别:{类别}
* 模式:{专用/通用}
2. 已创建资源:
* 支持模板:{列表}
* 文档更新:{列表}
3. 使用说明:
* 命令:`/{前缀}:{名称}`
* 示例:{示例用法}
4. 后续步骤:
* 测试命令
* 根据使用情况改进
* 添加到命令文档 </final_output>
每周安装次数
206
仓库
GitHub 星标
699
首次出现
2026年2月19日
安装于
opencode201
github-copilot200
codex200
gemini-cli199
kimi-cli197
cursor197
Contains Shell Commands
This skill contains shell command directives (!command``) that may execute system commands. Review carefully before installing.
This meta-command helps create other commands by:
<command_categories>
Planning Commands (Specialized)
Implementation Commands (Generic with Modes)
Analysis Commands (Specialized)
Workflow Commands (Specialized)
Utility Commands (Generic or Specialized)
<command_frontmatter>
All command files MUST begin with YAML frontmatter enclosed in --- delimiters:
---
description: Brief description of what the command does
argument-hint: Description of expected arguments (optional)
---
description (REQUIRED):
argument-hint (OPTIONAL):
# Planning Command
---
description: Interactive brainstorming session for new feature ideas
argument-hint: Optional initial feature concept
---
# Implementation Command
---
description: Implements features using mode-based patterns (ui, core, mcp)
argument-hint: Mode and feature description (e.g., 'ui: add dark mode toggle')
---
# Analysis Command
---
description: Comprehensive code review with quality assessment
argument-hint: Optional file or directory path to review
---
# Utility Command
---
description: Validates API documentation against OpenAPI standards
argument-hint: Path to OpenAPI spec file
---
------ before content begins </command_frontmatter><command_features>
Use subdirectories to group related commands. Subdirectories appear in the command description but don't affect the command name.
Example:
.claude/commands/frontend/component.md creates /component with description "(project:frontend)"~/.claude/commands/component.md creates /component with description "(user)"Priority: If a project command and user command share the same name, the project command takes precedence.
$ARGUMENTSCaptures all arguments passed to the command:
# Command definition
echo 'Fix issue #$ARGUMENTS following our coding standards' > .claude/commands/fix-issue.md
# Usage
> /fix-issue 123 high-priority
# $ARGUMENTS becomes: "123 high-priority"
$1, $2, etc.Access specific arguments individually using positional parameters:
# Command definition
echo 'Review PR #$1 with priority $2 and assign to $3' > .claude/commands/review-pr.md
# Usage
> /review-pr 456 high alice
# $1 becomes "456", $2 becomes "high", $3 becomes "alice"
Execute bash commands before the slash command runs using the ! prefix. The output is included in the command context.
Note: You must include allowed-tools with the Bash tool.
---
allowed-tools: Bash(git add:*), Bash(git status:*), Bash(git commit:*)
description: Create a git commit
---
## Context
- Current git status: !`git status`
- Current git diff: !`git diff HEAD`
- Current branch: !`git branch --show-current`
- Recent commits: !`git log --oneline -10`
Include file contents using the @ prefix to reference files:
Review the implementation in @src/utils/helpers.js
Compare @src/old-version.js with @src/new-version.js
Slash commands can trigger extended thinking by including extended thinking keywords.
| Frontmatter | Purpose | Default |
|---|---|---|
allowed-tools | List of tools the command can use | Inherits from conversation |
argument-hint | Expected arguments for auto-completion | None |
description | Brief description of the command | First line from prompt |
model | Specific model string | Inherits from conversation |
disable-model-invocation |
Example with all frontmatter options:
---
allowed-tools: Bash(git add:*), Bash(git status:*), Bash(git commit:*)
argument-hint: [message]
description: Create a git commit
model: claude-3-5-haiku-20241022
---
Create a git commit with message: $ARGUMENTS
</command_features>
<pattern_research>
List existing commands in target directory :
ls -la /.claude/commands/
# For user commands
ls -la ~/.claude/commands/
2. Read similar commands for patterns :
* Check the frontmatter (description and argument-hint)
* How do they structure sections?
* What MCP tools do they use?
* How do they handle arguments?
* What documentation do they reference?
3. Common patterns to look for :
# MCP tool usage for tasks
Use tool: mcp__scopecraft-cmd__task_create
Use tool: mcp__scopecraft-cmd__task_update
Use tool: mcp__scopecraft-cmd__task_list
# NOT CLI commands
❌ Run: scopecraft task list
✅ Use tool: mcp__scopecraft-cmd__task_list
4. Standard references to include :
* @/docs/organizational-structure-guide.md
* @/docs/command-resources/{relevant-templates}
* @/docs/claude-commands-guide.md </pattern_research>
<interview_process>
"Let's create a new command. First, let me check what similar commands exist..."
Use Glob to find existing commands in the target category
"Based on existing patterns, please describe:"
Based on responses and existing examples:
Study similar commands first :
# Read a similar command
@{similar-command-path}
# Note patterns:
- Task description style
- Argument handling
- MCP tool usage
- Documentation references
- Human review sections
🎯 Critical Decision: Where should this command live?
Project Command (/.claude/commands/)
User Command (~/.claude/commands/)
Ask: "Should this be:
Check existing resources:
# Check templates
ls -la /docs/command-resources/planning-templates/
ls -la /docs/command-resources/implement-modes/
# Check which guides exist
ls -la /docs/
</interview_process>
<generation_patterns>
Before generating, read similar commands and note:
Frontmatter (MUST BE FIRST) :
description: Clear one-line description of command purpose
argument-hint: What arguments does it accept
---
* No blank lines before opening `---`
* One blank line after closing `---`
* `description` is REQUIRED
* `argument-hint` is OPTIONAL
2. MCP Tool Usage :
# From existing commands
Use mcp__scopecraft-cmd__task_create
Use mcp__scopecraft-cmd__feature_get
Use mcp__scopecraft-cmd__phase_list
3. Standard References :
<context>
Key Reference: @/docs/organizational-structure-guide.md
Template: @/docs/command-resources/planning-templates/{template}.md
Guide: @/docs/claude-commands-guide.md
</context>
4. Task Update Patterns :
<task_updates>
After implementation:
1. Update task status to appropriate state
2. Add implementation log entries
3. Mark checklist items as complete
4. Document any decisions made
</task_updates>
5. Human Review Sections :
<human_review_needed>
Flag decisions needing verification:
- [ ] Assumptions about workflows
- [ ] Technical approach choices
- [ ] Pattern-based suggestions
</human_review_needed>
</generation_patterns>
<implementation_steps>
Create Command File
Create Supporting Files (if project command)
/docs/command-resources/Update Documentation (if project command)
Test the Command
<creation_checklist> Before finalizing:
---)<example_session> User: "I need a command to help validate our API documentation"
🔍 Research : Let me check existing analysis commands...
Use Read tool to examine: /.claude/commands/review.md
I notice the review command:
🤔 Question : Can you tell me more about this API documentation validation?
User: "It's OpenAPI specs, need to check for completeness and consistency"
💡 Category : This is an Analysis command similar to 'review'.
🔍 Pattern Check : Looking at review.md, I see it:
<task>
You are a code reviewer conducting a comprehensive review...
</task>
<mcp_usage>
Always use MCP tools:
- mcp__scopecraft-cmd__task_list
- mcp__scopecraft-cmd__task_update
</mcp_usage>
🎯 Location Question : Should this be:
User: "Project command - it needs to reference our specific API standards"
✅ Creating project command: /.claude/commands/validate-api.md
Generated command (following review.md patterns):
---
description: Validates API documentation against OpenAPI standards for completeness and consistency
argument-hint: Path to OpenAPI spec file (optional, will search if not provided)
---
<task>
You are an API documentation validator reviewing OpenAPI specifications for completeness and consistency.
</task>
<context>
References:
- API Standards: @/docs/api-standards.md
- Organizational Structure: @/docs/organizational-structure-guide.md
Similar to: @/.claude/commands/review.md
</context>
<validation_process>
1. Load OpenAPI spec files
2. Check required endpoints documented
3. Validate response schemas
4. Verify authentication documented
5. Check for missing examples
</validation_process>
<mcp_usage>
If issues found, create tasks:
- Use tool: mcp__scopecraft-cmd__task_create
- Type: "bug" or "documentation"
- Phase: Current active phase
- Area: "docs" or "api"
</mcp_usage>
<human_review_needed>
Flag for manual review:
- [ ] Breaking changes detected
- [ ] Security implications unclear
- [ ] Business logic assumptions
</human_review_needed>
</example_session>
<final_output> After gathering all information:
Command Created :
Resources Created :
Usage Instructions :
/{prefix}:{name}Next Steps :
Weekly Installs
206
Repository
GitHub Stars
699
First Seen
Feb 19, 2026
Installed on
opencode201
github-copilot200
codex200
gemini-cli199
kimi-cli197
cursor197
AI Elements:基于shadcn/ui的AI原生应用组件库,快速构建对话界面
62,200 周安装
剪映AI视频生成自动化脚本 - 基于Playwright的Seedance 2.0模型文生图/图生视频工具
204 周安装
社交媒体内容策略指南:LinkedIn、Twitter、Instagram、TikTok、Facebook平台优化与模板
204 周安装
Python statsmodels 统计建模与计量经济学分析库 - 回归、时间序列、假设检验
204 周安装
Azure PostgreSQL 无密码身份验证配置指南:Entra ID 迁移与访问管理
34,800 周安装
阅读清单管理器:基于Zettelkasten和间隔重复的智能阅读追踪与知识管理工具
Proposal Designer 提案设计师:创建视觉提案,提升用户体验与设计系统
Prevent Skill tool from calling this command |
| false |