Flutter开发之iOS真机调试(六)

1、首先你要有个开发者帐号。
2、真机数据线直连Mac 电脑,并保持解锁状态。
3、选择真机设备运行工程。ios

VS Code 终端执行web

lxx-Mac-mini:uuuu suning$ flutter run
More than one device connected; please specify a device with the '-d <deviceId>' flag, or use '-d all' to act on all devices.

user_lxx     • e18037498f5********************af3a9ac64 • ios • iOS 12.3
iPhone 6-8-4 • B63E6005-8E76-4289-A952-30692DF8948B     • ios • com.apple.CoreSimulator.SimRuntime.iOS-8-4 (simulator)

提示咱们:有两个设备。用-d ‘deviceId’ 来选择要运行的设备app

lxx-Mac-mini:uuuu suning$ flutter run -d e18037498f5********************af3a9ac64

执行后:
在这里插入图片描述编辑器

要你选择Mac 开发 仍是iPhone 开发,选择 2 。后就在真机上跑起来了。svg

若是使用Android studio 编辑器真机调试iOS 设备,要先打开Xcode General 中Team 选择一下,Profile,以及bundled 使Xcode 在真机上跑起来。在使用Android studio 编辑器跑真机