From efd25795bc5cf6bd56e319a848a69fea64ab7aea Mon Sep 17 00:00:00 2001 From: Christopher Snowhill Date: Mon, 3 Apr 2017 17:52:17 -0700 Subject: [PATCH] Now build inside source tree instead of using GUI Archive feature. --- .gitignore | 1 + Scripts/build.sh | 10 ++++++++++ Scripts/update_feed.rb | 8 +++++--- 3 files changed, 16 insertions(+), 3 deletions(-) create mode 100755 Scripts/build.sh diff --git a/.gitignore b/.gitignore index 47042c229..9995793c2 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ .DS_Store xcuserdata +build diff --git a/Scripts/build.sh b/Scripts/build.sh new file mode 100755 index 000000000..d9be111d2 --- /dev/null +++ b/Scripts/build.sh @@ -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 + diff --git a/Scripts/update_feed.rb b/Scripts/update_feed.rb index daa733508..7c58a21a3 100755 --- a/Scripts/update_feed.rb +++ b/Scripts/update_feed.rb @@ -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)