Reputation: 3447
I would like to run the following command in my Terminal of Android Studio.:
adb kill-server
adb start-server
I am getting the issue:
Command not found.
I have already read that I have to add the path somehow. But I do not understand how it should be done...
I am running Android Studio 2.2 on Windows 10 Pro.
Upvotes: 2
Views: 6082
Reputation: 1028
If you don't want to modify your system environment and instead keep the changes local to Android Studio, do this:
Goto Settings -> Tools -> Terminal
Add ANDROID_SDK_ROOT=C:\Users\<your username>\AppData\Local\Android\Sdk
to "Environment variables". Separate multiple variables with semicolon (;
) or use the GUI tool (Shift+Enter). Modify the path to point to your SDK installation as needed.
Change "Shell path" to C:\Windows\System32\cmd.exe /k "set "PATH=%ANDROID_SDK_ROOT%\platform-tools;%PATH%" "
Notes:
ANDROID_SDK_ROOT
is used for the installation directory of the SDK according to the documentation.Upvotes: 1
Reputation: 4209
If you are using mac or linux, you can try like this
export ANDROID_HOME=/Users/$(whoami)/Library/Android/sdk
export PATH=$PATH:$ANDROID_HOME/platform-tools
Now Check
adb status
Upvotes: 1
Reputation:
if you are still getting same error,simply go to your sdk location in terminal and type cd platform-tools .Then start doing what you want to do.adb works here. :)
Upvotes: 0