#!/bin/bash
# 作業ディレクトリ作成
mkdir build
# Archive作成
xcodebuild -workspace hogehoge.xcworkspace \
-scheme hogehoge \
-configuration Debug \
clean archive \
-archivePath ./build/build
# Exportしてipa作成
xcodebuild -exportArchive \
-archivePath ./build/build.xcarchive \
-exportPath ./build \
-exportOptionsPlist exportOptions.plist
# Deploygateにupload
if (( $# > 0 )); then
dg deploy ./build/hogehoge.ipa --message "$1"
else
dg deploy ./build/hogehoge.ipa
fi
exportOptions.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>compileBitcode</key>
<false/>
<key>method</key>
<string>development</string>
<key>signingStyle</key>
<string>automatic</string>
<key>stripSwiftSymbols</key>
<true/>
<key>teamID</key>
<string>XXXXXXXX</string>
<key>thinning</key>
<string><none></string>
</dict>
</plist>