简体   繁体   English

在设备上运行React Native应用

[英]Run React Native app In device

I am trying to develop simple react native app , i am new in this i get following error , can any one help me ? 我正在尝试开发简单的React Native应用程序,对此我是新手,但我遇到了以下错误,有人可以帮助我吗?

JS server already running.
'adb' is not recognized as an internal or external command,
operable program or batch file.
Building and installing the app on the device (cd android && gradlew.bat   install
Debug...
:app:preBuild UP-TO-DATE
:app:preDebugBuild UP-TO-DATE
:app:checkDebugManifest
:app:preReleaseBuild UP-TO-DATE
:app:prepareComAndroidSupportAppcompatV72301Library UP-TO-DATE
:app:prepareComAndroidSupportRecyclerviewV72301Library UP-TO-DATE
:app:prepareComAndroidSupportSupportV42321Library UP-TO-DATE
:app:prepareComFacebookFrescoDrawee0110Library UP-TO-DATE
:app:prepareComFacebookFrescoFbcore0110Library UP-TO-DATE
:app:prepareComFacebookFrescoFresco0110Library UP-TO-DATE
:app:prepareComFacebookFrescoImagepipeline0110Library UP-TO-DATE
:app:prepareComFacebookFrescoImagepipelineBase0110Library UP-TO-DATE
:app:prepareComFacebookFrescoImagepipelineOkhttp30110Library UP-TO-DATE
:app:prepareComFacebookReactReactNative0350Library UP-TO-DATE
:app:prepareComFacebookSoloaderSoloader010Library UP-TO-DATE
:app:prepareOrgWebkitAndroidJscR174650Library UP-TO-DATE
:app:prepareDebugDependencies
:app:compileDebugAidl UP-TO-DATE
:app:compileDebugRenderscript UP-TO-DATE 
:app:generateDebugBuildConfig UP-TO-DATE
:app:generateDebugAssets UP-TO-DATE
:app:mergeDebugAssets UP-TO-DATE
:app:generateDebugResValues UP-TO-DATE
:app:generateDebugResources UP-TO-DATE
:app:mergeDebugResources UP-TO-DATE
:app:bundleDebugJsAndAssets SKIPPED
:app:processDebugManifest UP-TO-DATE
:app:processDebugResources
 Unknown source file : ERROR: asset directory 'C:\Windows\System32\himanitest\and
 roid\app\build\intermediates\assets\debug' does not exist

:app:processDebugResources FAILED

FAILURE: Build failed with an exception.

 * What went wrong:
Execution failed for task ':app:processDebugResources'.

com.android.ide.common.process.ProcessException: org.gradle.process.internal.E xecException: Process 'command 'D:\\sdk\\build-tools\\23.0.1\\aapt.exe'' finished wi th non-zero exit value 1 com.android.ide.common.process.ProcessException:org.gradle.process.internal.E xecException:进程'D'\\ sdk \\ build-tools \\ 23.0.1 \\ aapt.exe命令完成零退出值1

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug
option to get more log output.

BUILD FAILED

Total time: 8.394 secs
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

I upgraded compileSdkVersion and buildToolsVersion and it works 我升级了compileSdkVersion和buildToolsVersion并且它可以工作

I upgraded it from compileSdkVersion 23 buildToolsVersion "23.0.1" to 我从compileSdkVersion 23 buildToolsVersion“ 23.0.1”升级到

compileSdkVersion 25
buildToolsVersion "25.0.1"

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 无法通过VS Code在Android设备上运行React本机应用程序 - Cannot run React native app on android device through VS Code 无法在react-native run-android上的设备上安装应用程序 - Could not install the app on the device on react-native run-android 在设备上运行时反应本机应用程序出错 - react native app having error when run on device 如何在 Android 设备上运行带有 Node js 后端的 React Native 应用程序? - How to run a React Native App with Node js Backend on Android Device? 无法通过隧道在物理设备上运行我的本机应用程序 - Can't run my react native app on physical device by tunnel 我的 React Native 应用程序可以在后台运行以收听来自蓝牙设备的消息以唤醒应用程序吗? - Can my React Native app run in the background to listen to message from a Bluetooth device to wake the app up? 尝试在 MI MAX 2 android 设备上运行本机应用程序时应用程序安装调试任务期间出现安全异常 - SecurityException during app:installDebug Task while attempting to run react-native app on MI MAX 2 android device React Native 无法在 Android 设备中运行 - React Native won't run in Android device 将本机项目运行到三星设备中 - Run react native project into samsung device 无法在Android设备上运行react-native - Unable to run react-native on android device
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM