我需要运行一个adb前进命令之前,我可以使用ezkeyboard应用程序,允许用户使用浏览器在手机上输入。

当我运行adb forward tcp:8080 tcp:8080命令时,我得到adb命令not found错误消息。

我可以从终端运行android命令。为什么亚洲开发银行没有发挥作用?


当前回答

在我的Mac (OS X 10.8.5)上,我在这里有adb:

~/Library/android-sdk-mac_86/platform-tools

因此,在.bash_profile中编辑$PATH并对其进行源化。

其他回答

UNABLE TO LOCATE ADB #SOLVED Simply Download Sdk platform tools.https://developer.android.com/studio/releases/platform-tools.html Extract the Downloaded file. Go to Sdk Manager in Android Studio and copy the link. Go to file Explorer and paste the path for Sdk you copied to view the Sdk files. You will notice that the Adb file is missing, open downloaded file (platform tools) copy contents and replace every content in your Sdk tool file (the file where you noticed adb is missing)and save. You are good to go.

我通过安装adb包解决了这个问题。我用的是Ubuntu。

sudo apt install adb

我想这对你有帮助。

考虑到您已经下载了SDK平台工具。这些命令适用于MAC用户。

该命令将在本地设置ADB。因此,如果您关闭终端并再次打开它,ADB命令将无法工作,直到您再次运行此命令。

export PATH=~/Library/Android/sdk/platform-tools:$PATH

这些命令将在全球范围内设置ADB。因此,一旦运行这些命令,下次就不需要再设置它们了。

echo 'export PATH=$PATH:~/Library/Android/sdk/platform-tools/' >> ~/.bash_profile

source ~/.bash_profile

确保adb在用户的$PATH变量中。

or

您可以尝试使用whereis定位它,并使用./adb运行它

在我的例子中,我在platform-tools目录中,但以错误的方式使用命令:

adb install

而不是正确的方式:

./adb install