Reusable iOS script for Travis CI with Testflight, Crittercism and HockeyApp support
- Install travis CLI if needed:
sudo gem install travis
- Install xctool if needed:
brew install xctool
- Copy "_travis.yml.sample" file to ".travis.yml"
- Fill in necessary info. on ".travis.yml":
- App Name
- Developer Name
- Provision Profile Name
- Project Workspace Name
- Scheme Name
- Slack Integration Key
- Add Travis secure environment variable by
travis encrypt "VariableName=VariableValue" --add
- Place all encrypted cert and private key in cert directory
openssl aes-256-cbc -k "<ENCRYPTION_SECRET>" -in dist.cer -out ./certs/dist.cer.enc -a
openssl aes-256-cbc -k "<ENCRYPTION_SECRET>" -in dist.p12 -out ./certs/dist.p12.enc -a
- Place all encrypted provision profile in profile directory
openssl aes-256-cbc -k "<ENCRYPTION_SECRET>" -in <PROFILE_NAME>.mobileprovision -out ./profile/<PROFILE_NAME>.mobileprovision.enc -a
- Add encryption secret key:
travis encrypt "ENCRYPTION_SECRET=<Encryption Secret Key>" --add
- Add protection password for private key:
travis encrypt "KEY_PASSWORD=<Protection Password>" --add
- Enable uploading testflight branch (configured by
APPLE_TESTFLIGHT_UPLOAD_BRANCH
in.travis.yml
file) to iTunes Connect by iTuen Connect account:travis encrypt "DELIVER_PASSWORD=<Password>" --add
- Enable uploading hockeyapp branch (configured by
HOCKEYAPP_UPLOAD_BRANCH
in.travis.yml
file) to HockeyApp by adding App ID and App Token:travis encrypt "HOCKEY_APP_ID=<App ID>" --add
travis encrypt "HOCKEY_APP_TOKEN=<App Token>" --add
- Enable uploading dSYM file to Crittercism by adding App ID and API Key:
travis encrypt "CRITTERCISM_APP_ID=<App ID>" --add
travis encrypt "CRITTERCISM_KEY=<API Key>" --add