2

This may have been the case in earlier versions of Xcode, but I am not sure. I noticed that archiving using a command line (like a script via jenkins would do) DOES NOT allow me to override the configuration using the xcodebuild argument option.

Example:

I would like to produce an archive of "TestScheme" using a workspace file "testscheme.xcworkspace"

Here is the relevant piece of my TestScheme.xcscheme

<ArchiveAction      
buildConfiguration = "Ad Hoc"
revealArchiveInOrganizer = "YES">
</ArchiveAction>

Here is what I run at the command line to build my archive:

xcodebuild -scheme TestScheme -workspace testscheme.xcworkspace -configuration someotherconfig archive

What is produced is an archive built with the "Ad Hoc" configuration. I poured over my xcscheme file, xcworkspace dir and the like and I can't see why the "-configuration" command line argument has no effect whatsoever.

  • 1
    Have a look at this question, it's kind of old but might help: http://stackoverflow.com/questions/8562031/xcodebuild-arguments-ignored-when-using-archive?rq=1 – Jeremy Fox Jul 11 '13 at 16:08
  • This seems to be the right explanation, but it seems strange that Apple has not repaired that since 4.2, Seems possible though. Maybe someone knows something else about this. – user1331793 Jul 11 '13 at 17:52

0 Answers0