0
I tried several answers to the below error found right here in the OS but none solved the problem. Running the command sudo ionic build android
is returned the following message
Error: Failed to find 'ANDROID_HOME' environment variable. Try setting setting it manually.
Detected 'android' command at /opt/android-studio/bin but no 'tools' directory found near.
Try reinstall Android SDK or update your PATH to include path to valid SDK directory.
ANDROID_HOME and PATH environment variables appear to be configured correctly
leonardo@antunesleo:~/projects/devcoffee/coffee-force$ echo $PATH
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/home/leonardo/Android/Sdk/tools:/home/leonardo/Android/Sdk/platform-tools
leonardo@antunesleo:~/projects/devcoffee/coffee-force$ echo $ANDROID_HOME
/home/leonardo/Android/Sdk
My Sdk is in the directory shown below.
/home/leonardo/Android/Sdk
the tools and Platform-tools directory is inside the Sdk, as expected.
leonardo@antunesleo:~/Android/Sdk$ ls
add-ons build-tools extras licenses Link para SDK Readme.txt platforms platform-tools SDK Readme.txt sources tools
Does anyone have any idea what might be going on?