0

I want to clean, build and create .ipa file using an ant script. Also I need to set the application icon. I searched the web but couldn't find a solution. And i prefer to run the ant through the terminal.

nath
  • 2,848
  • 12
  • 45
  • 75

2 Answers2

0

Try searching for Ant + XCodeBuild. There should be plenty examples out there that give you a general idea how you can script an XCode build from ANT.

Key is the terminal xcodebuild command and you can only do this with Ant if you run your build on a Mac.

Jeroen Leenarts
  • 502
  • 4
  • 11
0

You can create a script.sh instead a Ant with this:

#!/bin/sh

cd {PROJECT_BUILDDIR}
xcodebuild -sdk iphoneos5.1 -configuration Release "ARCHS=armv6 armv7" clean build


/usr/bin/xcrun -sdk iphoneos PackageApplication -v "${PROJECT_BUILDDIR}/${PROJECT_NAME}.app" -o "${BUILD_HISTORY_DIR}/${APPLICATION_NAME}.ipa" --sign "${DEVELOPER_NAME}" --embed "${PROVISONING_PROFILE}"

And for start this, open Terminal and write:

sudo bash script.sh

This is is not tested, maybe exist a some small errors

For some tips

CReaTuS
  • 2,593
  • 1
  • 19
  • 31