Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Loop.xcodeproj/xcshareddata/xcschemes/Loop.xcscheme
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@
ActionType = "Xcode.IDEStandardExecutionActionsCore.ExecutionActionType.ShellScriptAction">
<ActionContent
title = "Run Script"
scriptText = "#!/bin/bash&#10;&#10;if [[ ! -d $SRCROOT ]]; then&#10;echo &quot;This script must be run from an Xcode Build Phase&quot;&#10;exit 1;&#10;fi&#10;&#10;# Globals&#10;Tag=&#10;Logfile=&#10;CFBundleVersion=&#10;CFBundleShortVersionString=&#10;&#10;function init_logging () {&#10; logdir=&quot;$HOME/Library/Logs/$PRODUCT_BUNDLE_IDENTIFIER&quot;&#10; mkdir -p $logdir&#10; Logfile=&quot;$logdir/archive_post_actions.log&quot;&#10; exec &gt;&gt; $Logfile 2&gt;&amp;1&#10;&#10; echo &quot;\n\n\n$(date) Beginning archive post-actions for $CONFIGURATION&quot;&#10;}&#10;&#10;function increment_bundle_version () {&#10; srcPlist=&quot;$1&quot;&#10; PlistBuddy=&quot;/usr/libexec/PlistBuddy&quot;&#10;&#10; CFBundleVersion=`$PlistBuddy -c &quot;Print CFBundleVersion&quot; $srcPlist`&#10; CFBundleShortVersionString=`$PlistBuddy -c &quot;Print CFBundleShortVersionString&quot; $srcPlist`&#10; Tag=&quot;$PRODUCT_NAME$PRODUCT_NAME_SUFFIX-$CFBundleShortVersionString-$CFBundleVersion&quot;&#10;&#10; # Increment the bundle version for future builds&#10; CFBundleVersionNext=$(($CFBundleVersion + 1))&#10; $PlistBuddy -c &quot;Set :CFBundleVersion $CFBundleVersionNext&quot; $srcPlist&#10;&#10; echo &quot;Updated build number of $srcPlist to $CFBundleVersionNext&quot;&#10;&#10; # Copy the new version to the settings bundle&#10; # settingsPlist=&quot;$SRCROOT/$PRODUCT_NAME/Settings.bundle/Root.plist&quot;&#10; # $PlistBuddy -c &quot;Set :PreferenceSpecifiers:0:DefaultValue $CFBundleShortVersionString ($CFBundleVersionNext)&quot; $settingsPlist&#10;&#10; git add $srcPlist &gt;&gt; $Logfile 2&gt;&amp;1&#10;}&#10;&#10;function commit_and_tag_changes () {&#10; cd &quot;$SRCROOT&quot;&#10;&#10; git commit -m &quot;Auto-commit with archive $Tag&quot; &gt;&gt; $Logfile 2&gt;&amp;1&#10; git tag $Tag &gt;&gt; $Logfile 2&gt;&amp;1&#10; git push &gt;&gt; $Logfile 2&gt;&amp;1&#10; git push --tags &gt;&gt; $Logfile 2&gt;&amp;1&#10;&#10; cd -&#10;}&#10;&#10;function merge_to_master () {&#10; cd &quot;$SRCROOT&quot;&#10;&#10; branch=$(git symbolic-ref --short HEAD)&#10;&#10; git checkout master &gt;&gt; $Logfile 2&gt;&amp;1&#10; git merge &quot;$branch&quot; &gt;&gt; $Logfile 2&gt;&amp;1&#10; git push &gt;&gt; $Logfile 2&gt;&amp;1&#10; git checkout &quot;$branch&quot; &gt;&gt; $Logfile 2&gt;&amp;1&#10;&#10; cd -&#10;}&#10;&#10;## Run&#10;&#10;init_logging&#10;increment_bundle_version &quot;$SRCROOT/$INFOPLIST_FILE&quot;&#10;increment_bundle_version &quot;$SRCROOT/WatchApp/Info.plist&quot;&#10;commit_and_tag_changes&#10;">
scriptText = "#!/bin/bash&#10;&#10;if [[ ! -d $SRCROOT ]]; then&#10;echo &quot;This script must be run from an Xcode Build Phase&quot;&#10;exit 1;&#10;fi&#10;&#10;# Globals&#10;Tag=&#10;Logfile=&#10;CFBundleVersion=&#10;CFBundleShortVersionString=&#10;&#10;function init_logging () {&#10; logdir=&quot;$HOME/Library/Logs/$PRODUCT_BUNDLE_IDENTIFIER&quot;&#10; mkdir -p $logdir&#10; Logfile=&quot;$logdir/archive_post_actions.log&quot;&#10; exec &gt;&gt; $Logfile 2&gt;&amp;1&#10;&#10; echo &quot;\n\n\n$(date) Beginning archive post-actions for $CONFIGURATION&quot;&#10;}&#10;&#10;function increment_bundle_version () {&#10; srcPlist=&quot;$1&quot;&#10; PlistBuddy=&quot;/usr/libexec/PlistBuddy&quot;&#10;&#10; CFBundleVersion=`$PlistBuddy -c &quot;Print CFBundleVersion&quot; $srcPlist`&#10; CFBundleShortVersionString=`$PlistBuddy -c &quot;Print CFBundleShortVersionString&quot; $srcPlist`&#10; Tag=&quot;v$CFBundleShortVersionString&quot;&#10;&#10; # Increment the bundle version for future builds&#10; CFBundleVersionNext=$(($CFBundleVersion + 1))&#10; $PlistBuddy -c &quot;Set :CFBundleVersion $CFBundleVersionNext&quot; $srcPlist&#10;&#10; echo &quot;Updated build number of $srcPlist to $CFBundleVersionNext&quot;&#10;&#10; # Copy the new version to the settings bundle&#10; # settingsPlist=&quot;$SRCROOT/$PRODUCT_NAME/Settings.bundle/Root.plist&quot;&#10; # $PlistBuddy -c &quot;Set :PreferenceSpecifiers:0:DefaultValue $CFBundleShortVersionString ($CFBundleVersionNext)&quot; $settingsPlist&#10;&#10; git add $srcPlist &gt;&gt; $Logfile 2&gt;&amp;1&#10;}&#10;&#10;function commit_and_tag_changes () {&#10; cd &quot;$SRCROOT&quot;&#10;&#10; git commit -m &quot;Auto-commit with archive $Tag&quot; &gt;&gt; $Logfile 2&gt;&amp;1&#10; git tag $Tag &gt;&gt; $Logfile 2&gt;&amp;1&#10; git push &gt;&gt; $Logfile 2&gt;&amp;1&#10; git push --tags &gt;&gt; $Logfile 2&gt;&amp;1&#10;&#10; cd -&#10;}&#10;&#10;function merge_to_master () {&#10; cd &quot;$SRCROOT&quot;&#10;&#10; branch=$(git symbolic-ref --short HEAD)&#10;&#10; git checkout master &gt;&gt; $Logfile 2&gt;&amp;1&#10; git merge &quot;$branch&quot; &gt;&gt; $Logfile 2&gt;&amp;1&#10; git push &gt;&gt; $Logfile 2&gt;&amp;1&#10; git checkout &quot;$branch&quot; &gt;&gt; $Logfile 2&gt;&amp;1&#10;&#10; cd -&#10;}&#10;&#10;## Run&#10;&#10;init_logging&#10;increment_bundle_version &quot;$SRCROOT/$INFOPLIST_FILE&quot;&#10;increment_bundle_version &quot;$SRCROOT/WatchApp/Info.plist&quot;&#10;commit_and_tag_changes&#10;">
<EnvironmentBuildable>
<BuildableReference
BuildableIdentifier = "primary"
Expand Down