Xcode-MCP 是一款功能强大的命令行工具,可简化 macOS 和 iOS 应用程序的开发、测试与分发流程。它整合了各类 Xcode 工具和现代设备控制功能,能有效提升开发者的工作效率。
xcode-list-schemes --project /Users/username/Projects/MyApp.xcodeproj
xcode-test --project /Users/username/Projects/MyApp.xcodeproj --scheme MyApp --configuration Debug
xcode-archive --project /Users/username/Projects/MyApp.xcodeproj --scheme MyApp --configuration Release --output /Users/username/Desktop/MyApp.ipa
我需要检查我的Xcode项目,运行一些测试,然后打包进行分发。
1. 首先使用xcode-list-schemes工具列出我在/Users/username/Projects/MyApp.xcodeproj项目的所有方案。
2. 在看到方案后,请为第一个可用的方案在iPhone 14模拟器上运行测试。
3. 然后使用Release配置打包应用。
Project path: /Users/username/Projects/MyApp.xcodeproj
Project path: /Users/username/Projects/MyApp.xcodeproj
Scheme: MyApp
Destination: platform=iOS Simulator,name=iPhone 14
Project path: /Users/username/Projects/MyApp.xcodeprj
Scheme: MyApp
Configuration: Release
ArchivePath: /Users/username/Desktop/MyApp.ipa
该工具可执行 Xcode 相关命令,存在一定安全风险。请留意以下几点:
devicectl 和真机功能需要)# 克隆仓库
git clone https://github.com/yourusername/xcode-mcp.git
cd xcode-mcp
# 安装依赖项
npm install
# 启动开发服务器
npm run dev
# 构建项目
npm run build
# 运行测试
npm test
git checkout -b feature/new-feature
git add .
git commit -m "添加新功能"
git push origin feature/new-feature
通过遵循上述步骤,您可以高效使用 Xcode-MCP 工具管理开发流程。如需更多帮助,可随时查看问题跟踪页面或直接在 GitHub 上提交新问题。
感谢您选择 Xcode-MCP 工具!愿它为您的开发工作带来便利。