Re: [Solved] Train Wreck using xcodebuild in Xcode 6
Re: [Solved] Train Wreck using xcodebuild in Xcode 6
- Subject: Re: [Solved] Train Wreck using xcodebuild in Xcode 6
- From: Jerry Krinock <email@hidden>
- Date: Mon, 29 Sep 2014 19:09:34 -0700
> On 2014 Sep 29, at 12:31, Jens Alfke <email@hidden> wrote:
>
> Was the problem that PlistBuddy failed, but the shell script didn't tell Xcode about the error?
No, PlistBuddy returned the string "File Doesn't Exist, Will Create: …” instead of the value of a key. My script barfed on that and took an exit 15. And, xcodebuild did quit at that point, but because xcodebuild was in turn running inside of another script, it didn’t print out its usual ** BUILD FAILED ** in red. It just stopped and printed "Command /bin/sh failed with exit code 15”. You know, so much black on white text nowadays, I don’t always have time to read all of it :))
> Adding the "-e" flag to the shell arg list, or adding "set -e" at the top of the script, will cause the shell to exit and signal failure if any of its commands fail.
Nice, I never knew that.
* * *
I just fixed the same problem with another target. Simply moving that Shell Script Build Phase to run after Copy Resources definitely fixes it.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden