1

I get this Error when i run

ionic build android

Error screenshot

enter image description here

C:\Users\Ahmed\IonicProjects\first\firstIonicApp>ionic build android
Running command: "C:\Program Files\nodejs\node.exe"      C:\Users\Ahmed\IonicProjects
\first\firstIonicApp\hooks\after_prepare\010_add_platform_class.js   C:\Users\Ahme
d\IonicProjects\first\firstIonicApp
Running command: "C:\Program Files\nodejs\node.exe" C:\Users\Ahmed\IonicProjects
\first\firstIonicApp\hooks\after_prepare\020_remove_sass_from_platforms.js C:\Us
ers\Ahmed\IonicProjects\first\firstIonicApp
Running command: C:\Users\Ahmed\IonicProjects\first\firstIonicApp\platforms\andr
oid\cordova\build.bat
ANT_HOME is set incorrectly or ant could not be located. Please set ANT_HOME.
Built the following apk(s):

Also i want to know is it better to bootstrap ionic projects with yeoman? i already saw couple of tutorials doing that.

1
  • Did you add %ANT_HOME%\bin to your PATH? Commented Feb 13, 2015 at 9:41

2 Answers 2

2

based on this link, you need to the perform the following:

  1. Download and install Ant
  2. Set the ANT_HOME environment variable to the location where Ant was installed (Right Click >> Properties >> Advanced >> Environment Variables ...)
  3. Add %ANT_HOME%\bin to your PATH
  4. Open a command line and type "ant -version", and check if it is working.
Sign up to request clarification or add additional context in comments.

Comments

0

It looks like you dont have apache ant installed.go to: http://ant.apache.org/ and installed apache ant then create a ANT_HOME varriable in your system varriables and add your ant location to your PATH varriable

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.