I am trying to run a hybrid app on my android phone using ionic using the following command:
sudo ionic run android
However I keep receiving this 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.
I have already added platform tools & tools to PATH updated ANDROID_HOME
to point to my sdk root.
The ANDROID_HOME
environment variable shows up when I run env
and the PATH
has the tools and platform tools too. Additionally I can execute android
too. It launches the SDK Manager as expected.
Details:
ANDROID_HOME
: /home/user/Android/Sdk
$PATH
: /home/user/Android/Sdk/tools:/home/user/Android/Sdk/platform-tools
Please help! This is driving me up the wall!