Created
February 25, 2015 09:02
-
-
Save yuiseki/b581a005310467c6df0d to your computer and use it in GitHub Desktop.
XCodeでipaの出力がうまく行かない時に、最新っぽいarchivesからipaを無理やり生成するスクリプト
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
ipa_base="debug" | |
ipa_ext=".ipa" | |
profile="iOSTeam Provisioning Profile: *" | |
archives="/Users/$USER/Library/Developer/Xcode/Archives/" | |
newest_dir=`ls -lt $archives|head -n 2|tail -n 1|cut -f 13- -d " "` | |
echo $newest_dir | |
newest_ipa=`ls -lt $archives$newest_dir|head -n 2|tail -n 1|cut -f 13- -d " "` | |
echo $newest_ipa | |
filename=${ipa_base}_${newest_dir//-/_}${ipa_ext} | |
echo $filename | |
xcodebuild -exportArchive -archivePath "$archives$newest_dir/$newest_ipa"\ | |
-exportProvisioningProfile "$profile" -exportPath ./$filename |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment