Last active
August 29, 2015 14:08
-
-
Save anlcan/a2693812747b45b422a1 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 | |
echo "---------------------------------" | |
# FIXME : getting version from build *without* PilstBuddy | |
#VERSION=`/usr/libexec/PlistBuddy -c "Print CFBundleShortVersionString" OdeAlClient/OdeAlClient-Info.plist | tr . -` | |
VERSION="" | |
PROTOCOL="https" | |
PROJECT="odeal" | |
echo $CONFIGURATION | |
if [[ $CONFIGURATION == 'Debug' ]] | |
then | |
echo "DEV" | |
TARGET="ode-al-dev.appspot.com" | |
elif [[ $CONFIGURATION == 'Release' ]] | |
then | |
echo "RELEASE" | |
TARGET="ode-al-stage.appspot.com" | |
elif [[ $CONFIGURATION == 'Prod' ]] | |
then | |
echo "PROD" | |
VERSION="" | |
TARGET="ode-al.appspot.com" | |
fi | |
HOST=$TARGET | |
if [[ $CONFIGURATION == 'Local' ]] | |
then | |
echo "RELEASE" | |
HOST="localhost:8080" | |
PROTOCOL="http" | |
VERSION="" | |
fi | |
echo "connecting" $HOST | |
# Tell libcurl to *not* verify the peer. | |
# you disable this with -k/--insecure. | |
ZIP=$PROJECT.zip | |
curl -v -k "$PROTOCOL://$VERSION$HOST/handsome?target=objc" -o $ZIP | |
if [ -f $ZIP ]; then | |
mv $ZIP OdeAlClient/ | |
cd OdeAlClient | |
rm -rf $PROJECT | |
unzip $ZIP | |
fi | |
echo "---------------------------------" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment