Skip to content

Commit df7ff3b

Browse files
committed
Merge branch 'main' into 1.4.0-beta
2 parents 27501af + c86ce6e commit df7ff3b

File tree

16 files changed

+468
-109
lines changed

16 files changed

+468
-109
lines changed

.gitignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,10 +81,9 @@ xcuserdata/
8181
.cache
8282
.parcel-cache
8383

84-
# Windsurf rules
84+
# Windsurf
8585
.windsurfrules
8686

87-
8887
# Sentry Config File
8988
.sentryclirc
9089

.windsurf/workflows/build-app.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
description: Build and run the app on the iOS simulator
3+
---
4+
5+
1. Build the app
6+
2. Run the app on the simulator
7+
3. Only use tools exposed by XcodeBuildMCP

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# Changelog
22

3+
## [v1.3.7] - 2025-05-08
4+
- Fix Claude Code issue due to long tool names
5+
36
## [v1.4.0-beta.3] - 2025-05-07
47
- Fixed issue where incremental builds would only work for "Debug" build configurations
58
-

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ A Model Context Protocol (MCP) server that provides Xcode-related tools for inte
2323
- [Diagnostic Tool](#diagnostic-tool)
2424
- [Using with mise](#using-with-mise)
2525
- [Using with npx](#using-with-npx)
26+
- [MCP Server Logs](#mcp-server-logs)
2627
- [Privacy](#privacy)
2728
- [What is sent to Sentry?](#what-is-sent-to-sentry)
2829
- [Opting Out of Sentry](#opting-out-of-sentry)
@@ -200,6 +201,17 @@ The diagnostic tool will output comprehensive information about:
200201

201202
When reporting issues on GitHub, please include the full output from the diagnostic tool to help with troubleshooting.
202203

204+
### MCP Server Logs
205+
206+
It can be helpful to have access to the log messages from the MCP server to identify any issues. The logs are captured by the client application, for example in Cursor:
207+
208+
Cursor:
209+
```bash
210+
find ~/Library/Application\ Support/Cursor/logs -name "Cursor MCP.log" -exec zip -r matching_logs.zip {} +
211+
```
212+
213+
If your MCP client doesn't have log files you can run the server directly using the MCP Inspector tool see [Debugging](CONTRIBUTING.md#debugging) for more information on how to do this. Once running the MCP tool prints all log messages to it's error pane, which can be helpful in diagnosing issues.
214+
203215
## Privacy
204216

205217
This project uses [Sentry](https://sentry.io/) for error monitoring and diagnostics. Sentry helps us track issues, crashes, and unexpected errors to improve the reliability and stability of XcodeBuildMCP.

example_projects/iOS/Makefile

Lines changed: 339 additions & 0 deletions
Large diffs are not rendered by default.

src/tools/app_path.ts

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -181,14 +181,14 @@ async function _handleGetAppPathLogic(params: {
181181
// --- Public Tool Definitions ---
182182

183183
/**
184-
* Registers the get_macos_app_path_workspace tool
184+
* Registers the get_mac_app_path_ws tool
185185
*/
186186
export function registerGetMacOSAppPathWorkspaceTool(server: McpServer): void {
187187
type Params = BaseWorkspaceParams & { configuration?: string; arch?: string };
188188
registerTool<Params>(
189189
server,
190-
'get_macos_app_path_workspace',
191-
"Gets the app bundle path for a macOS application using a workspace. IMPORTANT: Requires workspacePath and scheme. Example: get_macos_app_path_workspace({ workspacePath: '/path/to/workspace', scheme: 'MyScheme' })",
190+
'get_mac_app_path_ws',
191+
"Gets the app bundle path for a macOS application using a workspace. IMPORTANT: Requires workspacePath and scheme. Example: get_mac_app_path_ws({ workspacePath: '/path/to/workspace', scheme: 'MyScheme' })",
192192
{
193193
workspacePath: workspacePathSchema,
194194
scheme: schemeSchema,
@@ -214,14 +214,14 @@ export function registerGetMacOSAppPathWorkspaceTool(server: McpServer): void {
214214
}
215215

216216
/**
217-
* Registers the get_macos_app_path_project tool
217+
* Registers the get_mac_app_path_proj tool
218218
*/
219219
export function registerGetMacOSAppPathProjectTool(server: McpServer): void {
220220
type Params = BaseProjectParams & { configuration?: string; arch?: string };
221221
registerTool<Params>(
222222
server,
223-
'get_macos_app_path_project',
224-
"Gets the app bundle path for a macOS application using a project file. IMPORTANT: Requires projectPath and scheme. Example: get_macos_app_path_project({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme' })",
223+
'get_mac_app_path_proj',
224+
"Gets the app bundle path for a macOS application using a project file. IMPORTANT: Requires projectPath and scheme. Example: get_mac_app_path_proj({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme' })",
225225
{
226226
projectPath: projectPathSchema,
227227
scheme: schemeSchema,
@@ -247,14 +247,14 @@ export function registerGetMacOSAppPathProjectTool(server: McpServer): void {
247247
}
248248

249249
/**
250-
* Registers the get_ios_device_app_path_workspace tool
250+
* Registers the get_ios_dev_app_path_ws tool
251251
*/
252252
export function registerGetiOSDeviceAppPathWorkspaceTool(server: McpServer): void {
253253
type Params = BaseWorkspaceParams & { configuration?: string };
254254
registerTool<Params>(
255255
server,
256-
'get_ios_device_app_path_workspace',
257-
"Gets the app bundle path for an iOS physical device application using a workspace. IMPORTANT: Requires workspacePath and scheme. Example: get_ios_device_app_path_workspace({ workspacePath: '/path/to/workspace', scheme: 'MyScheme' })",
256+
'get_ios_dev_app_path_ws',
257+
"Gets the app bundle path for an iOS physical device application using a workspace. IMPORTANT: Requires workspacePath and scheme. Example: get_ios_dev_app_path_ws({ workspacePath: '/path/to/workspace', scheme: 'MyScheme' })",
258258
{
259259
workspacePath: workspacePathSchema,
260260
scheme: schemeSchema,
@@ -278,14 +278,14 @@ export function registerGetiOSDeviceAppPathWorkspaceTool(server: McpServer): voi
278278
}
279279

280280
/**
281-
* Registers the get_ios_device_app_path_project tool
281+
* Registers the get_ios_dev_app_path_proj tool
282282
*/
283283
export function registerGetiOSDeviceAppPathProjectTool(server: McpServer): void {
284284
type Params = BaseProjectParams & { configuration?: string };
285285
registerTool<Params>(
286286
server,
287-
'get_ios_device_app_path_project',
288-
"Gets the app bundle path for an iOS physical device application using a project file. IMPORTANT: Requires projectPath and scheme. Example: get_ios_device_app_path_project({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme' })",
287+
'get_ios_dev_app_path_proj',
288+
"Gets the app bundle path for an iOS physical device application using a project file. IMPORTANT: Requires projectPath and scheme. Example: get_ios_dev_app_path_proj({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme' })",
289289
{
290290
projectPath: projectPathSchema,
291291
scheme: schemeSchema,
@@ -309,14 +309,14 @@ export function registerGetiOSDeviceAppPathProjectTool(server: McpServer): void
309309
}
310310

311311
/**
312-
* Registers the get_simulator_app_path_by_name_workspace tool
312+
* Registers the get_sim_app_path_name_ws tool
313313
*/
314314
export function registerGetSimulatorAppPathByNameWorkspaceTool(server: McpServer): void {
315315
type Params = BaseWorkspaceParams & BaseAppPathSimulatorNameParams;
316316
registerTool<Params>(
317317
server,
318-
'get_simulator_app_path_by_name_workspace',
319-
"Gets the app bundle path for a simulator by name using a workspace. IMPORTANT: Requires workspacePath, scheme, platform, and simulatorName. Example: get_simulator_app_path_by_name_workspace({ workspacePath: '/path/to/workspace', scheme: 'MyScheme', platform: 'iOS Simulator', simulatorName: 'iPhone 16' })",
318+
'get_sim_app_path_name_ws',
319+
"Gets the app bundle path for a simulator by name using a workspace. IMPORTANT: Requires workspacePath, scheme, platform, and simulatorName. Example: get_sim_app_path_name_ws({ workspacePath: '/path/to/workspace', scheme: 'MyScheme', platform: 'iOS Simulator', simulatorName: 'iPhone 16' })",
320320
{
321321
workspacePath: workspacePathSchema,
322322
scheme: schemeSchema,
@@ -348,14 +348,14 @@ export function registerGetSimulatorAppPathByNameWorkspaceTool(server: McpServer
348348
}
349349

350350
/**
351-
* Registers the get_simulator_app_path_by_name_project tool
351+
* Registers the get_sim_app_path_name_proj tool
352352
*/
353353
export function registerGetSimulatorAppPathByNameProjectTool(server: McpServer): void {
354354
type Params = BaseProjectParams & BaseAppPathSimulatorNameParams;
355355
registerTool<Params>(
356356
server,
357-
'get_simulator_app_path_by_name_project',
358-
"Gets the app bundle path for a simulator by name using a project file. IMPORTANT: Requires projectPath, scheme, platform, and simulatorName. Example: get_simulator_app_path_by_name_project({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme', platform: 'iOS Simulator', simulatorName: 'iPhone 16' })",
357+
'get_sim_app_path_name_proj',
358+
"Gets the app bundle path for a simulator by name using a project file. IMPORTANT: Requires projectPath, scheme, platform, and simulatorName. Example: get_sim_app_path_name_proj({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme', platform: 'iOS Simulator', simulatorName: 'iPhone 16' })",
359359
{
360360
projectPath: projectPathSchema,
361361
scheme: schemeSchema,
@@ -387,14 +387,14 @@ export function registerGetSimulatorAppPathByNameProjectTool(server: McpServer):
387387
}
388388

389389
/**
390-
* Registers the get_simulator_app_path_by_id_workspace tool
390+
* Registers the get_sim_app_path_id_ws tool
391391
*/
392392
export function registerGetSimulatorAppPathByIdWorkspaceTool(server: McpServer): void {
393393
type Params = BaseWorkspaceParams & BaseAppPathSimulatorIdParams;
394394
registerTool<Params>(
395395
server,
396-
'get_simulator_app_path_by_id_workspace',
397-
"Gets the app bundle path for a simulator by UUID using a workspace. IMPORTANT: Requires workspacePath, scheme, platform, and simulatorId. Example: get_simulator_app_path_by_id_workspace({ workspacePath: '/path/to/workspace', scheme: 'MyScheme', platform: 'iOS Simulator', simulatorId: 'SIMULATOR_UUID' })",
396+
'get_sim_app_path_id_ws',
397+
"Gets the app bundle path for a simulator by UUID using a workspace. IMPORTANT: Requires workspacePath, scheme, platform, and simulatorId. Example: get_sim_app_path_id_ws({ workspacePath: '/path/to/workspace', scheme: 'MyScheme', platform: 'iOS Simulator', simulatorId: 'SIMULATOR_UUID' })",
398398
{
399399
workspacePath: workspacePathSchema,
400400
scheme: schemeSchema,
@@ -426,14 +426,14 @@ export function registerGetSimulatorAppPathByIdWorkspaceTool(server: McpServer):
426426
}
427427

428428
/**
429-
* Registers the get_simulator_app_path_by_id_project tool
429+
* Registers the get_sim_app_path_id_proj tool
430430
*/
431431
export function registerGetSimulatorAppPathByIdProjectTool(server: McpServer): void {
432432
type Params = BaseProjectParams & BaseAppPathSimulatorIdParams;
433433
registerTool<Params>(
434434
server,
435-
'get_simulator_app_path_by_id_project',
436-
"Gets the app bundle path for a simulator by UUID using a project file. IMPORTANT: Requires projectPath, scheme, platform, and simulatorId. Example: get_simulator_app_path_by_id_project({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme', platform: 'iOS Simulator', simulatorId: 'SIMULATOR_UUID' })",
435+
'get_sim_app_path_id_proj',
436+
"Gets the app bundle path for a simulator by UUID using a project file. IMPORTANT: Requires projectPath, scheme, platform, and simulatorId. Example: get_sim_app_path_id_proj({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme', platform: 'iOS Simulator', simulatorId: 'SIMULATOR_UUID' })",
437437
{
438438
projectPath: projectPathSchema,
439439
scheme: schemeSchema,

src/tools/build_ios_device.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,14 @@ import {
3333
// --- Tool Registration Functions ---
3434

3535
/**
36-
* Registers the ios_device_build_workspace tool.
36+
* Registers the build_ios_dev_ws tool.
3737
*/
3838
export function registerIOSDeviceBuildWorkspaceTool(server: McpServer): void {
3939
type Params = BaseWorkspaceParams;
4040
registerTool<Params>(
4141
server,
42-
'ios_device_build_workspace',
43-
"Builds an iOS app from a workspace for a physical device. IMPORTANT: Requires workspacePath and scheme. Example: ios_device_build_workspace({ workspacePath: '/path/to/MyProject.xcworkspace', scheme: 'MyScheme' })",
42+
'build_ios_dev_ws',
43+
"Builds an iOS app from a workspace for a physical device. IMPORTANT: Requires workspacePath and scheme. Example: build_ios_dev_ws({ workspacePath: '/path/to/MyProject.xcworkspace', scheme: 'MyScheme' })",
4444
{
4545
workspacePath: workspacePathSchema,
4646
scheme: schemeSchema,
@@ -71,14 +71,14 @@ export function registerIOSDeviceBuildWorkspaceTool(server: McpServer): void {
7171
}
7272

7373
/**
74-
* Registers the ios_device_build_project tool.
74+
* Registers the build_ios_dev_proj tool.
7575
*/
7676
export function registerIOSDeviceBuildProjectTool(server: McpServer): void {
7777
type Params = BaseProjectParams;
7878
registerTool<Params>(
7979
server,
80-
'ios_device_build_project',
81-
"Builds an iOS app from a project file for a physical device. IMPORTANT: Requires projectPath and scheme. Example: ios_device_build_project({ projectPath: '/path/to/MyProject.xcodeproj', scheme: 'MyScheme' })",
80+
'build_ios_dev_proj',
81+
"Builds an iOS app from a project file for a physical device. IMPORTANT: Requires projectPath and scheme. Example: build_ios_dev_proj({ projectPath: '/path/to/MyProject.xcodeproj', scheme: 'MyScheme' })",
8282
{
8383
projectPath: projectPathSchema,
8484
scheme: schemeSchema,

src/tools/build_ios_simulator.ts

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,7 @@ Next Steps:
334334
- Option 3: Launch app with logs in one step (for a fresh start):
335335
launch_app_with_logs_in_simulator({ simulatorUuid: '${simulatorUuid}', bundleId: '${bundleId}' })
336336
337-
When done with any option, use: stop_and_get_simulator_log({ logSessionId: 'SESSION_ID' })`,
337+
When done with any option, use: stop_sim_log_cap({ logSessionId: 'SESSION_ID' })`,
338338
},
339339
],
340340
};
@@ -363,8 +363,8 @@ export function registerIOSSimulatorBuildByNameWorkspaceTool(server: McpServer):
363363

364364
registerTool<Params>(
365365
server,
366-
'ios_simulator_build_by_name_workspace',
367-
"Builds an iOS app from a workspace for a specific simulator by name. IMPORTANT: Requires workspacePath, scheme, and simulatorName. Example: ios_simulator_build_by_name_workspace({ workspacePath: '/path/to/MyProject.xcworkspace', scheme: 'MyScheme', simulatorName: 'iPhone 16' })",
366+
'build_ios_sim_name_ws',
367+
"Builds an iOS app from a workspace for a specific simulator by name. IMPORTANT: Requires workspacePath, scheme, and simulatorName. Example: build_ios_sim_name_ws({ workspacePath: '/path/to/MyProject.xcworkspace', scheme: 'MyScheme', simulatorName: 'iPhone 16' })",
368368
{
369369
workspacePath: workspacePathSchema,
370370
scheme: schemeSchema,
@@ -411,8 +411,8 @@ export function registerIOSSimulatorBuildByNameProjectTool(server: McpServer): v
411411

412412
registerTool<Params>(
413413
server,
414-
'ios_simulator_build_by_name_project',
415-
"Builds an iOS app from a project file for a specific simulator by name. IMPORTANT: Requires projectPath, scheme, and simulatorName. Example: ios_simulator_build_by_name_project({ projectPath: '/path/to/MyProject.xcodeproj', scheme: 'MyScheme', simulatorName: 'iPhone 16' })",
414+
'build_ios_sim_name_proj',
415+
"Builds an iOS app from a project file for a specific simulator by name. IMPORTANT: Requires projectPath, scheme, and simulatorName. Example: build_ios_sim_name_proj({ projectPath: '/path/to/MyProject.xcodeproj', scheme: 'MyScheme', simulatorName: 'iPhone 16' })",
416416
{
417417
projectPath: projectPathSchema,
418418
scheme: schemeSchema,
@@ -459,8 +459,8 @@ export function registerIOSSimulatorBuildByIdWorkspaceTool(server: McpServer): v
459459

460460
registerTool<Params>(
461461
server,
462-
'ios_simulator_build_by_id_workspace',
463-
"Builds an iOS app from a workspace for a specific simulator by UUID. IMPORTANT: Requires workspacePath, scheme, and simulatorId. Example: ios_simulator_build_by_id_workspace({ workspacePath: '/path/to/MyProject.xcworkspace', scheme: 'MyScheme', simulatorId: 'SIMULATOR_UUID' })",
462+
'build_ios_sim_id_ws',
463+
"Builds an iOS app from a workspace for a specific simulator by UUID. IMPORTANT: Requires workspacePath, scheme, and simulatorId. Example: build_ios_sim_id_ws({ workspacePath: '/path/to/MyProject.xcworkspace', scheme: 'MyScheme', simulatorId: 'SIMULATOR_UUID' })",
464464
{
465465
workspacePath: workspacePathSchema,
466466
scheme: schemeSchema,
@@ -507,8 +507,8 @@ export function registerIOSSimulatorBuildByIdProjectTool(server: McpServer): voi
507507

508508
registerTool<Params>(
509509
server,
510-
'ios_simulator_build_by_id_project',
511-
"Builds an iOS app from a project file for a specific simulator by UUID. IMPORTANT: Requires projectPath, scheme, and simulatorId. Example: ios_simulator_build_by_id_project({ projectPath: '/path/to/MyProject.xcodeproj', scheme: 'MyScheme', simulatorId: 'SIMULATOR_UUID' })",
510+
'build_ios_sim_id_proj',
511+
"Builds an iOS app from a project file for a specific simulator by UUID. IMPORTANT: Requires projectPath, scheme, and simulatorId. Example: build_ios_sim_id_proj({ projectPath: '/path/to/MyProject.xcodeproj', scheme: 'MyScheme', simulatorId: 'SIMULATOR_UUID' })",
512512
{
513513
projectPath: projectPathSchema,
514514
scheme: schemeSchema,
@@ -555,8 +555,8 @@ export function registerIOSSimulatorBuildAndRunByNameWorkspaceTool(server: McpSe
555555

556556
registerTool<Params>(
557557
server,
558-
'ios_simulator_build_and_run_by_name_workspace',
559-
"Builds and runs an iOS app from a workspace on a simulator specified by name. IMPORTANT: Requires workspacePath, scheme, and simulatorName. Example: ios_simulator_build_and_run_by_name_workspace({ workspacePath: '/path/to/workspace', scheme: 'MyScheme', simulatorName: 'iPhone 16' })",
558+
'build_run_ios_sim_name_ws',
559+
"Builds and runs an iOS app from a workspace on a simulator specified by name. IMPORTANT: Requires workspacePath, scheme, and simulatorName. Example: build_run_ios_sim_name_ws({ workspacePath: '/path/to/workspace', scheme: 'MyScheme', simulatorName: 'iPhone 16' })",
560560
{
561561
workspacePath: workspacePathSchema,
562562
scheme: schemeSchema,
@@ -603,8 +603,8 @@ export function registerIOSSimulatorBuildAndRunByNameProjectTool(server: McpServ
603603

604604
registerTool<Params>(
605605
server,
606-
'ios_simulator_build_and_run_by_name_project',
607-
"Builds and runs an iOS app from a project file on a simulator specified by name. IMPORTANT: Requires projectPath, scheme, and simulatorName. Example: ios_simulator_build_and_run_by_name_project({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme', simulatorName: 'iPhone 16' })",
606+
'build_run_ios_sim_name_proj',
607+
"Builds and runs an iOS app from a project file on a simulator specified by name. IMPORTANT: Requires projectPath, scheme, and simulatorName. Example: build_run_ios_sim_name_proj({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme', simulatorName: 'iPhone 16' })",
608608
{
609609
projectPath: projectPathSchema,
610610
scheme: schemeSchema,
@@ -651,8 +651,8 @@ export function registerIOSSimulatorBuildAndRunByIdWorkspaceTool(server: McpServ
651651

652652
registerTool<Params>(
653653
server,
654-
'ios_simulator_build_and_run_by_id_workspace',
655-
"Builds and runs an iOS app from a workspace on a simulator specified by UUID. IMPORTANT: Requires workspacePath, scheme, and simulatorId. Example: ios_simulator_build_and_run_by_id_workspace({ workspacePath: '/path/to/workspace', scheme: 'MyScheme', simulatorId: 'SIMULATOR_UUID' })",
654+
'build_run_ios_sim_id_ws',
655+
"Builds and runs an iOS app from a workspace on a simulator specified by UUID. IMPORTANT: Requires workspacePath, scheme, and simulatorId. Example: build_run_ios_sim_id_ws({ workspacePath: '/path/to/workspace', scheme: 'MyScheme', simulatorId: 'SIMULATOR_UUID' })",
656656
{
657657
workspacePath: workspacePathSchema,
658658
scheme: schemeSchema,
@@ -699,8 +699,8 @@ export function registerIOSSimulatorBuildAndRunByIdProjectTool(server: McpServer
699699

700700
registerTool<Params>(
701701
server,
702-
'ios_simulator_build_and_run_by_id_project',
703-
"Builds and runs an iOS app from a project file on a simulator specified by UUID. IMPORTANT: Requires projectPath, scheme, and simulatorId. Example: ios_simulator_build_and_run_by_id_project({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme', simulatorId: 'SIMULATOR_UUID' })",
702+
'build_run_ios_sim_id_proj',
703+
"Builds and runs an iOS app from a project file on a simulator specified by UUID. IMPORTANT: Requires projectPath, scheme, and simulatorId. Example: build_run_ios_sim_id_proj({ projectPath: '/path/to/project.xcodeproj', scheme: 'MyScheme', simulatorId: 'SIMULATOR_UUID' })",
704704
{
705705
projectPath: projectPathSchema,
706706
scheme: schemeSchema,

0 commit comments

Comments
 (0)