目前我在登录 React Native 时遇到问题。 我尝试了命令:'react-native log-android' 但显示错误 adb 调用失败。你的 PATH 中有 adb 吗? 我已经研究了答案,但仍然有一些链接没有找到任何解决方案。
这是完整的日志伙计们
Scanning folders for symlinks in C:\wamp\www\ProjectAwesome\node_modules (49ms)
Starting the logger (c:\Users\gr351\AppData\Local\Android\Sdk/platform-tools/adb logcat *:S ReactNative:V ReactNativeJS:V)...
adb invocation failed. Do you have adb in your PATH?
(node:7696) UnhandledPromiseRejectionWarning: undefined
(node:7696) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:7696) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
最佳答案
ADB PATH 有错误,"\""/"的用法,你给了
c:\Users\gr351\AppData\Local\Android\Sdk/platform-tools/adb
但应该是
c:\Users\gr351\AppData\Local\Android**\Sdk\platform-tools\adb**
关于android - react-native log-android adb 调用失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48819553/