Created
May 9, 2016 05:12
-
-
Save paulz/7cac11ad9a2229c6920c7c2004e0a2fc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash -l | |
brew install ios-sim | |
brew link ios-sim | |
DEVICE_TYPE_ID="com.apple.CoreSimulator.SimDeviceType.iPhone-6s, 9.3" | |
available=$(ios-sim showdevicetypes | grep "$DEVICE_TYPE_ID" -c) | |
if (( available >= 1 )) | |
then | |
dir=`mktemp -d` && pushd $dir | |
unzip "$(dirname "$0")"/My.app.zip &>/dev/null | |
ios-sim launch ./My.app --devicetypeid "$DEVICE_TYPE_ID" | |
popd | |
else | |
echo "Could not find $DEVICE_TYPE_ID within the output of: ios-sim showdevicetypes" | |
exit 1 | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment