2
votes

I have followed all the tutorials that is to be followed and done the settings correctly. I am getting the following error

[Error: Failed to find 'ANDROID_HOME' environment variable. Try setting setting it manually.
Failed to find 'android' command in your 'PATH'. Try update your 'PATH' to include path to valid SDK directory.]

Now possible solution to the problem is to add the path to your Android sdk in the $ANDROID_HOME and $PATH variable

Here is the output

echo $PATH

/home/samyak/anaconda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/local/java/jdk1.8.0_65/bin:/usr/local/java/jdk1.8.0_65/jre/bin:/usr/local/java/jdk1.8.0_65/bin:/usr/local/java/jdk1.8.0_65/jre/bin:/home/samyak/Android/Sdk/tools:/home/samyak/Android/Sdk/platform-tools

echo $ANDROID_HOME

/home/samyak/Android/Sdk

as soon as I do android I get the gui of android. I think I am missing something. If somebody could help me out

Version details
Ionic 1.7.11
Cordova 5.4.0
Android-sdk 23

Also to note that I did not download the Android Sdk but took it from a friend via hard drive? Will that effect my android build?

1
Please follow this tutorial ,blog.nraboy.com/2014/09/… It will be helpful for youMuhsin Keloth

1 Answers

0
votes

Make sure you have the Android Tools inside the path folder.After you have the Android SDK downloaded and installed, you need to install build tools for the version of android you're targeting. You will need to check:

  • Tools
  • Targeted Android API Version
  • Extras

and hit Install in the Android SDK Manager. If something is missing after this, install what build tool is complaining about.