搜索

PythonReactSEOPDF
GitHub Skill

command-patterns

Advanced patterns for generating high-quality Claude Code commands. Used by /new-command.

majesticlabs-dev☆ 20 仓库 Stars3 仓库 Forks

安装与使用

请根据来源仓库和你的 AI 工具说明安装此技能。先阅读技能文件和依赖要求,再添加到工作流。

查看来源 ↗使用指南

技能说明

Command Patterns Skill

Expert patterns for generating production-quality Claude Code commands.

Core Requirements

  1. Multiple Action Modes - Never single-purpose commands

    • analyze - Deep analysis
    • optimize - Performance improvements
    • fix - Automated remediation
    • monitor - Continuous watching
  2. Real, Working Code - Every example must be executable

  3. Intelligent Recommendations - Prioritized, actionable insights

  4. Interactive Intelligence - Guide users to optimal solutions

  5. Visual Outputs - Include diagrams/charts when helpful

Advanced Patterns

Progressive Disclosure
# Simple for beginners
claude /your-command

# Power user with full control
claude /your-command analyze --depth=comprehensive --output=json
Safe Automation with Rollbacks
apply_change() {
  # Snapshot current state
  kubectl get deployment $1 -o yaml > "/tmp/rollback-$$.yaml"

  # Apply change
  kubectl patch deployment $1 --patch "$2"

  # Monitor and rollback if needed
  if ! monitor_health $1 60; then
    kubectl apply -f "/tmp/rollback-$$.yaml"
  fi
}

Quality Checklist

Intelligence
  • Recognizes patterns from past executions
  • Provides insights humans would miss
  • Explains reasoning behind recommendations
User Experience
  • Works with zero configuration
  • Provides meaningful progress indicators
  • Offers escape hatches at every step
Safety
  • Every change has a rollback
  • Dry-run mode available
  • Confirms destructive operations
Integration
  • Outputs in multiple formats
  • Works in CI/CD pipelines
  • Provides hooks for customization

Frontmatter Template

---
description: Brief description  # REQUIRED
model: haiku                    # OPTIONAL - use full ID
allowed-tools: Bash, Read       # OPTIONAL
argument-hint: "[action]"       # OPTIONAL
---

The Ultimate Test

"Would a senior engineer with 10 years experience be impressed?"

If not emphatic YES, keep improving.

使用示例

查看来源仓库中的使用示例与配置说明。

查看来源 ↗

来源历史

收录时间
2026-01-20
索引更新时间
2026-02-04
Branch
main

收录与同步日期属于本站记录。源码修改历史请查看来源仓库。

GitHub ↗

chat Comments (0)

chat_bubble_outline

No comments yet. Be the first to share your thoughts!