Skip to content

Instantly share code, notes, and snippets.

@markcerqueira
Created January 11, 2015 19:52
Show Gist options
  • Save markcerqueira/0509fa26104142cb4cfe to your computer and use it in GitHub Desktop.
Save markcerqueira/0509fa26104142cb4cfe to your computer and use it in GitHub Desktop.
Crittercism Auto-Upload dSYM with API Key as an environmental variable
# only upload during Release builds, otherwise every build will upload a dSYM
if [ "${CONFIGURATION}" = "Release" ]; then
# put the secret key in this file as an environmental variable
if [ -f ~/.crittercism_keys ]; then
# this is required to inject the environmental variables into the shell spawned by Xcode
source ~/.crittercism_keys
APP_ID="MY_FIRST_APP_ID_abcdefghi"
# instead of having your API key here, it is copied in from the environmental varible
API_KEY=${MINI_AUDICLE_SECRET_KEY}
# run the script
source "${SRCROOT}"/ios/libs/Crittercism/dsym_upload.sh
else
echo "~/.crittercism_keys does not exist. Not uploading dSYM!"
fi
else
echo "Not a Release build so not auto-uploading dSYM file."
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment