如何在 XCode 6 iOS 模拟器中运行/录制 iOS 应用程序?

17
我可能有些错误,但我正在尝试在Xcode 6 iOS模拟器中运行iOS应用程序,以便记录应用程序的视频教程。我已安装xCode并可以启动iOS模拟器,但似乎没有办法安装.app文件。 ~/Library/Developer/CoreSimulator文件夹是一个完全的谜团,也没有明确的位置来放置app文件。
你有什么想法吗?
另外,是否有更简单的方法来录制iOS应用程序的视频?人们必须经常这样做来制作教程...
谢谢。

如果这是你的iOS应用,你有代码并且可以通过xCode构建和运行应用程序。你可以使用一些软件,如http://screenyapp.com,在模拟器上进行记录,或者使用http://ios.wonderhowto.com/how-to/record-your-ipads-iphones-screen-no-jailbreak-computer-required-0156864/之类的工具直接在你的手机上进行记录... - StrawHara
你可以在这里使用这种方法[https://dev59.com/CVwZ5IYBdhLWcg3wJ9cp#55843630]。 - Ali A. Jalil
你可以试试这个最简单的方法:链接 - Ali A. Jalil
3个回答

33

如果您在设备上运行应用程序,则可以使用新的Yosemite功能通过USB录制到QuickTime。

但由于您正在使用模拟器,因此需要在QuickTime中进行部分屏幕录制。

使用 QuickTime

启动QuickTime,然后转到“文件”>“新建屏幕录制”。您可以单击以选择整个屏幕,或者拖动以仅记录屏幕的一部分。

enter image description here

替代方案

如果您想要更多的灵活性,则需要使用第三方软件,如ScreenFlow


没错,这很容易。只需使用QuickTime即可。这是一个鲜为人知的功能! - Fattie
只是想指出,如果您从设备而不是模拟器录制,则会更容易实现上面提到的小点:https://developer.apple.com/app-store/app-previews/ - jemmons

4
从 Xcode 8.2 开始,您可以使用 xcrun 命令行工具拍摄模拟器窗口的截图或视频。
Launch your app in Simulator.
Launch Terminal (located in /Applications/Utilities), and enter the appropriate command:
To take a screenshot, use the screenshot operation:
xcrun simctl io booted screenshot

You can specify an optional filename at the end of the command.

To record a video, use the recordVideo operation:
xcrun simctl io booted recordVideo <filename>.<extension>

To stop recording, press Control-C in Terminal.

Note: You must specify a filename for recordVideo.
The default location for the created file is the current directory.
For more information on simctl, run this command in Terminal:

xcrun simctl help

For more information on the io subcommand of simctl, run this command:

xcrun simctl io help

请查看此链接以获取更多详细信息。

1
你可以使用 Xcode 中的“构建和运行”在 iOS 模拟器中安装和运行您的应用程序。或者,您可以运行 xcrun simctl install <Device UDID> <Path to app> 来安装您的应用程序。有关录制屏幕捕获视频的问题,您应该使用 QuickTime。

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接