Now build inside source tree instead of using GUI Archive feature.

CQTexperiment
Christopher Snowhill 2017-04-03 17:52:17 -07:00
parent e2b728f4d1
commit efd25795bc
3 changed files with 16 additions and 3 deletions

1
.gitignore vendored
View File

@ -1,2 +1,3 @@
.DS_Store
xcuserdata
build

10
Scripts/build.sh Executable file
View File

@ -0,0 +1,10 @@
#!/bin/sh
pushd $(dirname $0)
BASE=`pwd -P`
popd
BUILDPRODUCTS="$BASE"/build/Build/Products/Release
xcodebuild -workspace "$BASE"/../Cog.xcodeproj/project.xcworkspace -scheme Cog -configuration Release -derivedDataPath "$BASE"/build

View File

@ -36,9 +36,11 @@ appcast_revision_code = appcast_revision_split[1]
# end
# end
archivedir = "~/Library/Developer/Xcode/Archives"
latest_archive = %x[find #{archivedir} -type d -name 'Cog *.xcarchive' -print0 | xargs -0 stat -f "%m %N" -t "%Y" | sort -r | head -n1 | sed -E 's/^[0-9]+ //'].rstrip
app_path = "#{latest_archive}/Products#{ENV['HOME']}/Applications"
# archivedir = "~/Library/Developer/Xcode/Archives"
# latest_archive = %x[find #{archivedir} -type d -name 'Cog *.xcarchive' -print0 | xargs -0 stat -f "%m %N" -t "%Y" | sort -r | head -n1 | sed -E 's/^[0-9]+ //'].rstrip
# app_path = "#{latest_archive}/Products#{ENV['HOME']}/Applications"
script_path = File.expand_path(File.dirname(__FILE__))
app_path = "#{script_path}/build/Build/Products/Release"
plist = open("#{app_path}/Cog.app/Contents/Info.plist")
plistdoc = Document.new(plist)