Ganzolo
Ganzolo

Reputation: 1394

Continuous integration Xcode Server after trigger $XCS_PRODUCT not set

I had a bot that was working perfectly under Xcode 6.4. An after trigger script was automatically uploading the IPA using this path : "$XCS_OUTPUT_DIR/$XCS_PRODUCT"

However (even after redoing a bot from scratch) it appears that :

How to find my .ipa without this variable during my after trigger script?

Upvotes: 7

Views: 2146

Answers (1)

tadija
tadija

Reputation: 3261

I had the same problem and after discussion on Apple Developer Forums I found out that there actually is .IPA file inside

/Library/Developer/XcodeServer/Integrations/Integration-INTEGRATION_ID/ExportedProduct/

directory and you can access it from After Trigger Script by using something like

originalBinaryName=$(basename "${XCS_ARCHIVE%.*}".ipa)
originalBinaryPath="${XCS_OUTPUT_DIR}/ExportedProduct/Apps/${originalBinaryName}"

I have also sent a bug report, because $XCS_PRODUCT should not be empty anyway, and it would be nice to have new environment variable for the complete path of .IPA file.

Upvotes: 4

Related Questions