aboutsummaryrefslogtreecommitdiffstats
path: root/Scripts/build.sh
diff options
context:
space:
mode:
authorstuconnolly <stuart02@gmail.com>2013-01-03 19:05:02 +0000
committerstuconnolly <stuart02@gmail.com>2013-01-03 19:05:02 +0000
commitc626140ce65c3e9383d80e239562d54dc9f208e5 (patch)
treeec31f9d3069e3ff4a4083a566b14de895d912027 /Scripts/build.sh
parentdb10c94a14e8ce49668d4ab687c6d769ac7cb459 (diff)
downloadsequelpro-c626140ce65c3e9383d80e239562d54dc9f208e5.tar.gz
sequelpro-c626140ce65c3e9383d80e239562d54dc9f208e5.tar.bz2
sequelpro-c626140ce65c3e9383d80e239562d54dc9f208e5.zip
Tidy up build scripts.
Diffstat (limited to 'Scripts/build.sh')
-rwxr-xr-xScripts/build.sh25
1 files changed, 11 insertions, 14 deletions
diff --git a/Scripts/build.sh b/Scripts/build.sh
index 09bd09f6..d9d99d61 100755
--- a/Scripts/build.sh
+++ b/Scripts/build.sh
@@ -52,40 +52,37 @@ echo 'Updating build version...'
# Remove the .ibplugin from within frameworks
rm -rf "${BUILD_PRODUCT}/Contents/Frameworks/ShortcutRecorder.framework/Versions/A/Resources/ShortcutRecorder.ibplugin"
-# Perform localisation updates for 'Release' or 'Distribution' builds
+# Perform 'Release' or 'Distribution' build specific actions
if [[ "$CONFIGURATION" == 'Release' || "$CONFIGURATION" == 'Distribution' ]]
then
"${SRCROOT}/Scripts/localize.sh"
-fi
-# Trim the application if this is a 'Release' or 'Distribution' build
-if [[ "$CONFIGURATION" == 'Release' || "$CONFIGURATION" == 'Distribution' ]]
-then
- echo 'Running trim-application.sh to strip application resources for distribution...'
+ printf "Running trim-application.sh to strip application resources for distribution...\n\n"
"${SRCROOT}/Scripts/trim-application.sh" -p "$BUILD_PRODUCT" -a
fi
+SHARED_SUPPORT_DIR="${BUILD_PRODUCT}/Contents/SharedSupport"
+
# Copy all Default Bundles to build product
-rm -rf "${BUILD_PRODUCT}/Contents/SharedSupport/Default Bundles"
+rm -rf "${SHARED_SUPPORT_DIR}/Default Bundles"
-mkdir -p "${BUILD_PRODUCT}/Contents/SharedSupport/Default Bundles"
+mkdir -p "${SHARED_SUPPORT_DIR}/Default Bundles"
-cp -R "${SRCROOT}/SharedSupport/Default Bundles" "${BUILD_PRODUCT}/Contents/SharedSupport"
+cp -R "${SRCROOT}/SharedSupport/Default Bundles" "${SHARED_SUPPORT_DIR}"
# Copy all Default Themes to build product
-rm -rf "${BUILD_PRODUCT}/Contents/SharedSupport/Default Themes"
+rm -rf "${SHARED_SUPPORT_DIR}/Default Themes"
-mkdir -p "${BUILD_PRODUCT}/Contents/SharedSupport/Default Themes"
-
-cp -R "${SRCROOT}/SharedSupport/Default Themes" "${BUILD_PRODUCT}/Contents/SharedSupport"
+mkdir -p "${SHARED_SUPPORT_DIR}/Default Themes"
+cp -R "${SRCROOT}/SharedSupport/Default Themes" "${SHARED_SUPPORT_DIR}"
# Perform distribution specific tasks if this is a 'Distribution' build
if [ "$CONFIGURATION" == 'Distribution' ]
then
-
echo 'Checking for localizations to copy in, using the "ResourcesToCopy" directory...'
+
if [ -e "${SRCROOT}/ResourcesToCopy" ]
then
find "${SRCROOT}/ResourcesToCopy" \( -name "*.lproj" \) | while read FILE; do; printf "\tCopying localization: ${FILE}\n"; cp -R "$FILE" "${BUILD_PRODUCT}/Contents/Resources/"; done;