title: Xcode Bot: how to get .ipa path on a post trigger script?
body: <p>I'm using a bot to archive an iOS app, and I need to get the .ipa product path in order to publish it into our distribution system.</p>
  
  <p>Bot settings:</p>
  
  <p><a href="https://i.stack.imgur.com/MXHE5.png" rel="noreferrer"><img src="https://i.stack.imgur.com/MXHE5.png" alt="enter image description here"></a></p>
  
  <p>And using a script to print all env variables, non of them contains a path to the ipa file. In addition, some of the variables are pointed to directory that does not exist, i.e: <code>XCS_OUTPUT_DIR</code></p>
  
  <p>Here the env variable output:</p>
  
  <pre><code>XCS=1
  XCS_ANALYZER_WARNING_CHANGE=-31
  XCS_ANALYZER_WARNING_COUNT=0
  XCS_ARCHIVE=/Library/Developer/XcodeServer/Integrations/Integration-771867708dfac45bba10a1998c118912/MyApp.xcarchive
  XCS_BOT_ID=771867708dfac45bba10a1998c007d43
  XCS_BOT_NAME='MyApp Distribution'
  XCS_BOT_TINY_ID=DBB85BD
  XCS_DERIVED_DATA_DIR=/Library/Developer/XcodeServer/Integrations/Caches/771867708dfac45bba10a1998c007d43/DerivedData
  XCS_ERROR_CHANGE=-1
  XCS_ERROR_COUNT=0
  XCS_INTEGRATION_ID=771867708dfac45bba10a1998c118912
  XCS_INTEGRATION_NUMBER=19
  XCS_INTEGRATION_RESULT=warnings
  XCS_INTEGRATION_TINY_ID=F7D4469
  XCS_OUTPUT_DIR=/Library/Developer/XcodeServer/Integrations/Integration-771867708dfac45bba10a1998c118912
  XCS_SOURCE_DIR=/Library/Developer/XcodeServer/Integrations/Caches/771867708dfac45bba10a1998c007d43/Source
  XCS_TESTS_CHANGE=0
  XCS_TESTS_COUNT=0
  XCS_TEST_FAILURE_CHANGE=0
  XCS_TEST_FAILURE_COUNT=0
  XCS_WARNING_CHANGE=0
  XCS_WARNING_COUNT=26
  XCS_XCODEBUILD_LOG=/Library/Developer/XcodeServer/Integrations/Integration-771867708dfac45bba10a1998c118912/xcodebuild.log
  XPC_FLAGS=0x0
  XPC_SERVICE_NAME=com.apple.xcsbuildd
  </code></pre>
  
  <p>In addition to that, I was able to confirm that <code>.ipa</code> files are being created in another folder (<code>&lt;path to server&gt;/IntegrationAssets/&lt;integration id&gt;/&lt;integration number&gt;/</code>), but that path is not accessible from an env variable.</p>
  
  <p>Any ideas?</p>