我试图在ios真实设备上运行react-native应用程序.它在模拟器或使用xcode的设备上运行良好,但我想用命令行运行,我试过了。
>npm install -g ios-deploy
>react-native run-ios --device "My iPhone"
这是我得到的。
info Found Xcode workspace "Project.xcworkspace"
info Building (using "xcodebuild -workspace Project.xcworkspace -configuration Debug -scheme Project -destination id=00008020-0001395426EA002E")
......................................................................
2020-04-06 11:15:02.836 xcodebuild[16724:402803] DTDeviceKit: deviceType from 00008020-0001395426EA002E was NULL
2020-04-06 11:15:02.967 xcodebuild[16724:402797] DTDeviceKit: deviceType from 00008020-0001395426EA002E was NULL
info Installing and launching your app on My iPhone
该应用程序出现在我的iPhone,但不运行。
Metro反对在一个新的终端,但我得到的只有这一点。
###### ######
### #### #### ###
## ### ### ##
## #### ##
## #### ##
## ## ## ##
## ### ### ##
## ######################## ##
###### ### ### ######
### ## ## ## ## ###
### ## ### #### ### ## ###
## #### ######## #### ##
## ### ########## ### ##
## #### ######## #### ##
### ## ### #### ### ## ###
### ## ## ## ## ###
###### ### ### ######
## ######################## ##
## ### ### ##
## ## ## ##
## #### ##
## #### ##
## ### ### ##
### #### #### ###
###### ######
Welcome to React Native!
Learn once, write anywhere
To reload the app press "r"
To open developer menu press "d"
而且我没有得到用XCode构建时显示的进度条。
编辑
对于日志:
user@MBP Project % react-native log-ios
error No active iOS device found
安装版本 :
user@MBP Project % react-native -v
react-native-cli: 2.0.1
react-native: 0.62.0