aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTeddy Wing2018-10-08 18:19:39 +0200
committerTeddy Wing2018-10-08 18:23:46 +0200
commitce6854f2de7d6301a4b9937159536cc855ce8818 (patch)
treea55b5202f5853e622411ded7f487e0b0ece6e57b
parent995ec750f18f32217b9368b57bdef28d7ef64b30 (diff)
downloadWord-Count-ce6854f2de7d6301a4b9937159536cc855ce8818.tar.bz2
Add Makefile to build and archive the application
Thanks to these resources, in addition to the `xcodebuild` man page, for explaining how to do the archiving: - http://subathrathanabalan.com/2016/01/07/building-ipa-export-archive/ - https://medium.com/xcblog/xcodebuild-deploy-ios-app-from-command-line-c6defff0d8b8 - https://bitbar.com/tipstricks-how-to-archive-and-export-ipa-from-script/
-rw-r--r--Makefile20
-rw-r--r--export-options.plist9
2 files changed, 29 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..087c282
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,20 @@
+release:
+ xcodebuild -scheme 'Word Count' -configuration Release
+
+clean-release:
+ xcodebuild -project 'Word Count.xcodeproj' \
+ -configuration Release \
+ clean
+
+archive: clean-release release
+ xcodebuild -project 'Word Count.xcodeproj' \
+ -scheme 'Word Count' \
+ -configuration Release \
+ archive \
+ -archivePath build/Release.xcarchive
+
+ xcodebuild \
+ -exportArchive \
+ -archivePath build/Release.xcarchive \
+ -exportOptionsPlist export-options.plist \
+ -exportPath build
diff --git a/export-options.plist b/export-options.plist
new file mode 100644
index 0000000..98e54bb
--- /dev/null
+++ b/export-options.plist
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN"
+ "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>method</key>
+ <string>mac-application</string>
+</dict>
+</plist>