美文网首页
xcode 13 在终端用命令打开模拟器

xcode 13 在终端用命令打开模拟器

作者: 東玖零 | 来源:发表于2021-10-29 14:40 被阅读0次

xcode 13安装好后使用命令打开模拟器

xcrun instruments -w "iPhone 8 (14.3)" 
xcrun: error: Failed to locate 'instruments'.
xcrun: error: unable to find utility "instruments", not a developer tool or in PATH

几番查找发现这个命令已经过期了。

How to launch iOS simulator from Terminal
Run this command to see a list of available simulators and their UDID, then copy UDID of the device and run the next command.

$ xcrun simctl list
$ open -a Simulator --args -CurrentDeviceUDID <your device UDID>

The output example is:
iPhone 8 (F3991045-28ED-4703-B624-77449D5D1AE7) (Shutdown)
where the numbers are the UDID.

最终使用以下命令打开iphone 8。

open -a Simulator --args -CurrentDeviceUDID F3991045-28ED-4703-B624-77449D5D1AE7

相关文章

网友评论

      本文标题:xcode 13 在终端用命令打开模拟器

      本文链接:https://www.haomeiwen.com/subject/mzpialtx.html