Mac配置android环境变量,确认配置好了,还是提示没有配置。

ax$ react-native run-android
Starting JS server...
Building and installing the app on the device (cd android && ./gradlew installDebug...

Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/android-setup.html

jax$ adb devices
List of devices attached
192.168.56.101:5555 device

解决方案:

可能是android/gradlew的权限不够。第一步,在RN项目目录下执行chmod 755 android/gradlew,再执行react-native run-android试试,应该没问题了。

你可能感兴趣的:(Mac配置android环境变量,确认配置好了,还是提示没有配置。)