A versatile iOS code quality analysis tool that operates in two modes: 1. **CLI Tool**: Direct command-line interface for iOS testing and linting 2. **MCP Server**: Model Context Protocol server for AI assistant integration This tool provides comprehensive iOS code quality analysis and test automation capabilities, enabling both direct developer usage and AI assistant integration for Xcode tests, linter analysis, and detailed feedback on iOS projects through structured, actionable reports. Quick Start CLI Mode (Direct Usage with npx - Recommended) **Use instantly without installation:** Alternative: Install Globally (Optional) For frequent use across multiple projects, you can install globally: > **💡 Tip:** Using npx is recommended as it ensures you always use the latest version without global installs. MCP Server Mode (AI Assistant Integration) The server will start on http://localhost:3000 and be ready to receive MCP requests. Features - **🧪 iOS Test Execution**: Run Xcode tests with detailed failure analysis - **📱 Multiple Schemes Support**: Test different iOS project configurations - **🔍 SwiftLint Integration**: Automated Swift code style and quality checking - **📊 Structured Reporting**: Clear, actionable feedback with file locations and line numbers - **🛠 Build Error Detection**: Intelligent parsing of Xcode build failures - **🔒 Local Processing**: All analysis happens on your machine for security - **⚡ Dual Mode Operation**: Use as CLI tool or MCP server - **💻 Command Line Interface**: Direct terminal usage for developers - **🤖 AI Assistant Ready**: MCP protocol support for seamless AI integration Architecture This tool operates in two distinct modes with intelligent detection: CLI Mode - **Activation**: When command-line arguments are provided - **Usage**: Direct developer interaction via terminal commands or npx - **Output**: Human-readable or JSON format for scripting - **Benefits**: Fast execution, scriptable, CI/CD friendly, no installation required with npx MCP Server Mode - **Activation**: When no arguments are provided (default) - **Usage**: AI assistant integration via Model Context Protocol - **Output**: Structured MCP responses for AI consumption - **Benefits**: AI-powered analysis, contextual suggestions, interactive debugging **Simple Mode Detection:** CLI Usage No Installation Required Use npx to run the CLI directly without installation: Commands Test Command Run iOS tests with comprehensive analysis: **Test Command Options:** - --xcworkspace : Path to .xcworkspace file - --xcodeproj : Path to .xcodeproj file (either xcworkspace or xcodeproj required) - --scheme : Scheme name for testing (required) - --destination : Test destination (default: "platform=iOS Simulator") - --json: Output results in JSON format - --verbose: Enable verbose logging Lint Command Run SwiftLint analysis on specific files: **Lint Command Options:** - --changed-files : Comma-separated list of files to lint (required) - --config-path : Path to SwiftLint configuration file - --json: Output results in JSON format - --verbose: Enable verbose logging Server Command Start MCP server mode explicitly: CLI Examples MCP Server Installation Prerequisites - **Node.js 18+**: Required for running the MCP server - **Xcode**: For iOS project building and testing - **iOS Simulator**: For running tests (or physical iOS device) - **SwiftLint** (optional): For code quality analysis Setup Steps 1. **Clone the repository:** 2. **Install dependencies:** 3. **Build the project:** 4. **Start the server:** AI Assistant Integration Configure your AI assistant (Claude, Copilot, etc.) to use this MCP server: