Ubuntu – Adding Android SDK platform-tools to PATH downloaded from umake

androidandroid-sdkandroid-studiocommand line

I am using Ubuntu 14.04 Trusty Tahr, and I downloaded Android Studio with the umake tool provided by Ubuntu. This downloaded Android Studio at
/root/tools/android/android-studio,
and platform-tools and all other tools at –
/root/Android/Sdk/

Android Studio on my PC is working just fine, and I am able to create an application and also run it on my mobile phone using it. But I want command line access to the tools and so I want to add them to the environment path.

To add them to environment path, I did this-

nano ~/.bachrc

And added the following lines-

 export PATH=${PATH}:/root/Android/Sdk/platform-tools
 export PATH=${PATH}:/root/Android/Sdk/build-tools

But this dosen't work. When I give the command adb from a terminal, it dosen't seem to invoke the adb tools from the platform-tools folder. Instead it tells me to install android-tools-adb.

I am however being able to cd into platform-tools, and run adb and other tools from there, but I don't want to do that again and again. Also, how can I add Android Studio to my PATH so that I don't have to cd into its bin/ directory again and again?

Thank you very much in advance.

Best Answer

This worked for me

export PATH=$PATH:$HOME"/android-sdk-linux/platform-tools"
Related Question