💡 摘要
一个为Claude Code提供的综合性插件,包含用于软件开发工作流的专用代理、命令、技能和自动化钩子。
🎯 适合人群
🤖 AI 吐槽: “这是Claude的瑞士军刀,但你可能需要一本说明书才能找到开瓶器。”
该插件执行shell命令,访问文件系统进行格式化和扫描,并包含扫描密钥的安全钩子。它可以阻止对.env等敏感文件的编辑。一个具体风险是自动格式化钩子会在用户文件上执行外部二进制程序。缓解措施:在沙盒环境中运行插件,并审计其调用的外部工具。
project-starter
A universal Claude Code workflow plugin with specialized agents, skills, hooks, and output styles for any software project.
Quick Start
Option 1: CLI (Per-Session)
# Clone the plugin git clone https://github.com/CloudAI-X/claude-workflow.git # Run Claude Code with the plugin claude --plugin-dir ./claude-workflow
Option 2: Agent SDK
import { query } from "@anthropic-ai/claude-agent-sdk"; for await (const message of query({ prompt: "Hello", options: { plugins: [{ type: "local", path: "./claude-workflow" }], }, })) { // Plugin commands, agents, and skills are now available }
Option 3: Install Permanently
# Install from marketplace (when available) claude plugin install project-starter # Or install from local directory claude plugin install ./claude-workflow
Verify Installation
After loading the plugin, verify it's working:
> /plugin
Tab to Installed - you should see project-starter listed.
Tab to Errors - should be empty (no errors).
These commands become available:
/project-starter:architect # Architecture-first mode
/project-starter:rapid # Ship fast mode
/project-starter:commit # Auto-generate commit message
/project-starter:verify-changes # Multi-agent verification
What's Included
| Component | Count | Description | | ------------ | ----- | ------------------------------------------------------------------------ | | Agents | 7 | Specialized subagents for code review, debugging, security, etc. | | Commands | 17 | Slash commands for workflows and output styles | | Skills | 10 | Knowledge domains Claude uses autonomously | | Hooks | 9 | Automation scripts for formatting, security, verification, notifications |
Usage Examples
Commands in Action
Auto-commit your changes:
> /project-starter:commit
Looking at staged changes...
✓ Created commit: feat(auth): add JWT refresh token endpoint
Full git workflow:
> /project-starter:commit-push-pr
✓ Committed: feat: add user dashboard
✓ Pushed to origin/feature/dashboard
✓ Created PR #42: https://github.com/you/repo/pull/42
Verify before shipping:
> /project-starter:verify-changes
Spawning verification agents...
├─ build-validator: ✓ Build passes
├─ test-runner: ✓ 42 tests pass
├─ lint-checker: ⚠ 2 warnings (non-blocking)
└─ security-scanner: ✓ No vulnerabilities
Ready to ship!
Agents in Action
Agents spawn automatically based on your request:
You say: "The login is broken, users get 401 errors"
[debugger agent activated]
→ Checking auth middleware... found issue
→ Token validation uses wrong secret in production
→ Fix: Update AUTH_SECRET in .env.production
You say: "Review my changes"
[code-reviewer agent activated]
→ Analyzing 3 files changed...
✓ Logic is correct
⚠ Missing null check on line 42
⚠ Consider adding rate limiting to this endpoint
You say: "Add authentication to the API"
[orchestrator agent activated]
→ Breaking down into subtasks:
1. Design auth schema (spawning architect)
2. Implement JWT middleware
3. Add login/register endpoints
4. Write tests (spawning test-architect)
5. Update API docs (spawning docs-writer)
Skills in Action
Skills provide domain knowledge automatically:
You ask: "How should I structure the payment service?"
[designing-architecture skill applied]
→ Recommending hexagonal architecture
→ Payment providers as adapters
→ Core domain isolated from infrastructure
You ask: "Make this endpoint faster"
[optimizing-performance skill applied]
→ Adding database indexes
→ Implementing response caching
→ Using pagination for large results
Hooks in Action
Hooks run automatically on events:
Security block (pre-edit):
⛔ BLOCKED: Potential secret detected
File: src/config.ts, Line 5
Pattern: API key (sk-...)
Remove the secret and use environment variables.
Auto-format (post-edit):
✓ Formatted with prettier: src/components/Button.tsx
✓ Formatted with black: scripts/deploy.py
Desktop notifications:
🔔 "Claude needs input" - when waiting for your response
🔔 "Task complete" - when finished
Commands Reference
All commands use the format /project-starter:<command>.
Output Styles
| Command | Mode |
| ---------------------------- | --------------------------------------------- |
| /project-starter:architect | System design mode - architecture before code |
| /project-starter:rapid | Fast development - ship quickly, iterate |
| /project-starter:mentor | Teaching mode - explain the "why" |
| /project-starter:review | Code review mode - strict quality |
Git Workflow (Inner-Loop)
| Command | Purpose |
| ------------------------------------ | ----------------------------------------- |
| /project-starter:commit | Auto-generate conventional commit message |
| /project-starter:commit-push-pr | Commit → Push → Create PR (full workflow) |
| /project-starter:quick-fix | Fast fix for lint/type errors |
| /project-starter:add-tests | Generate tests for recent changes |
| /project-starter:lint-fix | Auto-fix all linting issues |
| /project-starter:sync-branch | Sync with main (rebase or merge) |
| /project-starter:summarize-changes | Generate standup/PR summaries |
Verification
| Command | Purpose |
| ---------------------------------- | --------------------------------------- |
| /project-starter:verify-changes | Multi-subagent adversarial verification |
| /project-starter:validate-build | Build process validation |
| /project-starter:run-tests | Tiered test execution |
| /project-starter:lint-check | Code quality checks |
| /project-starter:security-scan | Security vulnerability detection |
| /project-starter:code-simplifier | Post-implementation cleanup |
Agents
Agents are specialized subagents that Claude spawns automatically based on your task.
| Agent | Purpose | Auto-Triggers |
| ------------------ | -------------------------------- | ------------------------------------------- |
| orchestrator | Coordinate multi-step tasks | "improve", "refactor", multi-module changes |
| code-reviewer | Review code quality | After code changes, before commits |
| debugger | Systematic bug investigation | Errors, test failures, crashes |
| docs-writer | Technical documentation | README, API docs, guides |
| security-auditor | Security vulnerability detection | Auth, user input, sensitive data |
| refactorer | Code structure improvements | Technical debt, cleanup |
| test-architect | Design test strategies | Adding/improving tests |
Skills
Skills are knowledge domains that Claude uses autonomously when relevant.
| Skill | Domain |
| ----------------------------- | ----------------------------------------------------- |
| analyzing-projects | Understand codebase structure and patterns |
| designing-tests | Unit, integration, E2E test approaches |
| designing-architecture | Clean Architecture, Hexagonal, etc. |
| optimizing-performance | Speed up applications, identify bottlenecks |
| managing-git | Version control, conventional commits |
| designing-apis | REST/GraphQL patterns and best practices |
| parallel-execution | Multi-subagent parallel task execution patterns |
| web-design-guidelines | UI review against Vercel Web Interface Guidelines |
| vercel-react-best-practices | React/Next.js performance optimization (45 rules) |
| convex-backend | Convex backend development (functions, schemas, etc.) |
Hooks
Hooks run automatically on specific events.
| Hook | Trigger | Action |
| --------------------- | ------------- | -------------------------------------- |
| Security scan | Edit/Write | Blocks commits with potential secrets |
| File protection | Edit/Write | Blocks edits to lock files, .env, .git |
| Auto-format | Edit/Write | Runs prettier/black/gofmt by file type |
| Command logging | Bash | Logs to .claude/command-history.log |
| Environment check | Session start | Validates Node.js, Python, Git |
| Prompt analysis | User prompt | Suggests appropriate agents |
| Auto-verify | Task complete | Runs tests/lint, reports results |
| Input notification | Input needed | Desktop notification |
| Complete notification | Task complete | Des
优点
- 集成多个专用代理处理不同任务
- 自动化常见的git和验证工作流
- 包含用于代码质量的安全和格式化钩子
缺点
- 对于简单项目可能过于复杂
- 依赖外部工具(prettier, black等)
- 在创意编码阶段可能存在过度自动化的风险
相关技能
免责声明:本内容来源于 GitHub 开源项目,仅供展示和评分分析使用。
版权归原作者所有 CloudAI-X.
