1

I'm new to mac & xcode. Please tell me the procedure for iphone .xcodeproject outside xcode IDE for below tasks:

  1. Build- done using xcodebuild command
  2. deploy in simulator ?
  3. Run in simulator.?

How to achieve this using ant/Applescript?

Thanks in advance

Darin Kolev
  • 3,401
  • 13
  • 31
  • 46
Raj
  • 11
  • 1
  • 4
  • may be this will help you http://rajneesh071.blogspot.com/2013/04/launch-iphone-simulator-without-xcode.html – Rajneesh071 Apr 26 '13 at 14:17
  • @Rajneesh071 ,thanks for the link, it was pretty helpful, is it possible to achieve the same without using commandline utility like waxsim – Raj May 02 '13 at 07:16
  • yes you can do it using finder -> cmnd+shift_g and then provide path – Rajneesh071 May 02 '13 at 11:27
  • @Rajneesh071 , I followed the link you have provided, It was pretty useful in building and running but where I am stuck is how to run automated test case and build junit report without using xcode IDE Pls let me know anything regarding this – Raj May 03 '13 at 07:12
  • what is "automated test case" and "junit report" ? – Rajneesh071 May 03 '13 at 07:48
  • @Rajneesh071 automated test case= automate unit test cases outside xcode, junit report = xml test case report. correct if its wrong. – Raj May 06 '13 at 06:38
  • do you have any link for this.. i wanna learn this... – Rajneesh071 May 06 '13 at 08:01
  • this might help you, http://longweekendmobile.com/2012/11/11/ios-application-unit-tests-from-the-command-line-xcode-4-5-update/ http://redgreenrefactor.eu/blog/xcode-running-logic-and-applicationtests-form-command-line/ https://github.com/ciryon/OCUnit2JUnit http://baolei.tumblr.com/post/32428168156/ios-unit-test-from-command-line-ios6-xcode4-5 if you want anything specific just google. – Raj May 07 '13 at 08:42

1 Answers1

2

enter link description hereI know how to build and create .app file from out side Xcode i.e. with terminal. Open the terminal and go the specific folder where the project is created and use this command..

xcodebuild -workspace 'WORKSPACENAME.xcworkspace' -scheme 'APPNAME' -configuration "Debug" -sdk iphoneos6.0 -arch "armv7 armv7s" CONFIGURATION_BUILD_DIR='OUTPUT_DIRECTORY'

if you have static library attached to the project then

xcodebuild -workspace 'WORKSPACENAME.xcworkspace' -scheme 'APPNAME_LIB' -configuration "Debug-iphoneos" -sdk iphoneos6.0 -arch "armv7 armv7s" CONFIGURATION_BUILD_DIR='OUTPUT_DIRECTORY'
xcodebuild -workspace 'WORKSPACENAME.xcworkspace' -scheme 'APPNAME_LIB' -configuration "Debug" -sdk  iphoneos6.0  -arch "armv7 armv7s" CONFIGURATION_BUILD_DIR='OUTPUT_DIRECTORY'

also here is some useful links..

>  [https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man1/xcodebuild.1.html][2]
> [https://stackoverflow.com/questions/947317/can-i-install-an-app-to-the-simulator-without-the-source-code][3]
> [https://stackoverflow.com/questions/517463/how-can-i-install-a-ipa-file-to-my-iphone-simulator][4]
Community
  • 1
  • 1
User-1070892
  • 929
  • 10
  • 16
  • THanks for the reply,i did know xcodebuild command , but couldn't figure out how to deploy and run, let me know regarding the later – Raj Apr 26 '13 at 11:00