ios-debugger-agent
Install this skill
npx skills add dimillian/skillsWorks across Claude Code, Cursor, Codex, Copilot & Antigravity
The iOS Debugger Agent manages the interaction between AI assistants and local Xcode environments. It provides a structured interface for deploying apps to booted iOS simulators, navigating application hierarchies, and analyzing runtime logs. By orchestrating the XcodeBuildMCP protocol, the agent automates the discovery of simulator states, manages project schemes, and executes UI operations such as tapping, text entry, and gesture tracking. It bridges the gap between raw source code and dynamic simulator behavior, allowing developers to inspect UI states, confirm layout rendering, and capture debug output without manually switching contexts between the code editor and the simulator application. This agent transforms high-level user goals into specific simulator commands, ensuring that build parameters, bundle identifiers, and session defaults remain synchronized during the testing process.
When to Use This Skill
- β’Verifying UI layout responsiveness on a specific simulated device
- β’Reproducing crash reports by capturing live simulator logs
- β’Testing user flows such as login or data entry on a fresh build
- β’Confirming that recent code changes reflect correctly in the app interface
How to Invoke This Skill
Example prompts that trigger this skill in Claude Code, Cursor, or Antigravity:
- βDebug the current iOS build on the simulator
- βShow me the UI hierarchy for the running app
- βStart capturing logs and try to reproduce the login flow
- βFind the booted simulator and build the app
- βTap the submit button and check for error logs
Pro Tips
- π‘Always ensure an iOS simulator is pre-booted to expedite the debugging process; the skill can discover existing booted instances.
- π‘Leverage the `session-set-defaults` function to define your project path, scheme, and simulator ID once per session to reduce repetitive inputs.
- π‘Combine UI interaction requests with log capture to get a comprehensive view of what happened leading up to an issue.
What this skill does
- β’Identify and target active iOS simulators
- β’Automate build and launch cycles for specific app schemes
- β’Inspect UI element hierarchies via screen description tools
- β’Execute remote taps, text inputs, and navigation gestures
- β’Stream and summarize console logs directly from the simulator
When not to use it
- βWhen physical hardware device testing or debugging is required
- βIf the build environment or Xcode project configuration is corrupted or missing dependencies
- βFor tasks requiring non-simulated features like push notification hardware integration
Example workflow
- Confirm a simulator is currently booted
- Set the project path, scheme, and simulator ID as session defaults
- Build the application and launch it within the simulator environment
- Use describe_ui to identify the target interactable elements
- Perform the necessary UI actions and initiate log capture
- Stop log capture and analyze the resulting output for errors
Prerequisites
- βXcode installed on macOS
- βAn existing iOS project with valid scheme configurations
- βA booted iOS simulator instance
Pitfalls & limitations
- !Attempts to boot simulators automatically may fail due to system permissions
- !UI elements might report as non-hittable if the layout has not finished rendering
- !Incorrect scheme or bundle ID settings will cause build or launch failures
FAQ
How it compares
Unlike manual testing which requires constant context switching, this agent maintains persistent state information, allowing it to execute multi-step diagnostic workflows faster and with higher accuracy.
π Full skill instructions β original source: dimillian/skills
## Overview
Use XcodeBuildMCP to build and run the current project scheme on a booted iOS simulator, interact with the UI, and capture logs. Prefer the MCP tools for simulator control, logs, and view inspection.
## Core Workflow
Follow this sequence unless the user asks for a narrower action.
### 1) Discover the booted simulator
- Call
mcp__XcodeBuildMCP__list_sims and select the simulator with state Booted.- If none are booted, ask the user to boot one (do not boot automatically unless asked).
### 2) Set session defaults
- Call
mcp__XcodeBuildMCP__session-set-defaults with:-
projectPath or workspacePath (whichever the repo uses)-
scheme for the current app-
simulatorId from the booted device- Optional:
configuration: "Debug", useLatestOS: true### 3) Build + run (when requested)
- Call
mcp__XcodeBuildMCP__build_run_sim.- If the app is already built and only launch is requested, use
mcp__XcodeBuildMCP__launch_app_sim.- If bundle id is unknown:
1)
mcp__XcodeBuildMCP__get_sim_app_path2)
mcp__XcodeBuildMCP__get_app_bundle_id## UI Interaction & Debugging
Use these when asked to inspect or interact with the running app.
- **Describe UI**:
mcp__XcodeBuildMCP__describe_ui before tapping or swiping.- **Tap**:
mcp__XcodeBuildMCP__tap (prefer id or label; use coordinates only if needed).- **Type**:
mcp__XcodeBuildMCP__type_text after focusing a field.- **Gestures**:
mcp__XcodeBuildMCP__gesture for common scrolls and edge swipes.- **Screenshot**:
mcp__XcodeBuildMCP__screenshot for visual confirmation.## Logs & Console Output
- Start logs:
mcp__XcodeBuildMCP__start_sim_log_cap with the app bundle id.- Stop logs:
mcp__XcodeBuildMCP__stop_sim_log_cap and summarize important lines.- For console output, set
captureConsole: true and relaunch if required.## Troubleshooting
- If build fails, ask whether to retry with
preferXcodebuild: true.- If the wrong app launches, confirm the scheme and bundle id.
- If UI elements are not hittable, re-run
describe_ui after layout changes.How to Use This Skill Unit
Option A: Project-Specific (Recommended)
- Click "Download" above
- In your project, create the directory:
.agent/skills/ios-debugger-agent/ - Save the file as
SKILL.md - The agent will automatically discover the skill based on its description.
Option B: Global Installation (All Agents)
Save the file to these locations to make it available across all projects:
- Claude Code:
~/.claude/skills/dimillian/skills/ios-debugger-agent/SKILL.md - Cursor:
~/.cursor/skills/dimillian/skills/ios-debugger-agent/SKILL.md - Antigravity:
~/.gemini/antigravity/skills/dimillian/skills/ios-debugger-agent/SKILL.md
π Install with CLI:npx skills add dimillian/skills
