How ruvnet/ruv-dev works
Project Type and Purpose
• This is an open-source, Node.js-based CLI scaffolding tool.
• It generates SPARC-methodology projects, AIGI frameworks, or minimal Roo-mode frameworks.
• It also provides an interactive “MCP Wizard” for configuring external services.
1. User → CLI Entry Point (“runs npx create-sparc ...”)
2. CLI Entry → Command Parser → Selected Command Module
3. Command Module → Core Modules (ProjectGenerator, MCPWizard, etc.)
4. Core Modules ↔ Template Store (read templates)
5. Core Modules → FileManager → Output Files & .roo / .roomodes
6. MCPWizard → RegistryClient → External MCP Registry API
7. MCPWizard → External MCP Servers (via shell commands and environment variables)
Architectural Patterns & Design Principles
• Layered Architecture: Presentation (CLI), Application (commands), Domain (core modules), Infrastructure (FS, network).
• Command Pattern: each CLI command encapsulated in its own handler.
• Adapter/Client Pattern: RegistryClient adapts calls to external MCP registry.
• Template-Driven Scaffolding: separation of templates from code logic.
• Single Responsibility & Separation of Concerns: each core module has a distinct role.
• Configuration-as-Data: all service integrations driven by JSON (mcp.json, roomodes).
Technologies & Frameworks to Annotate
• Node.js + JavaScript (TypeScript optional)
• CLI parsing library (e.g., yargs or commander)
• Jest for tests (__tests__ folder)
• JSON schemas for config validation
• Symlink support via Node’s fs module
• Shell invocation (child_process) for MCP servers
• Templates managed in plain Markdown / code files