diff deploy/osx/deploy.sh @ 232:41ae9544a255

* Update Mac deployment stuff
author Chris Cannam
date Thu, 06 Jan 2011 15:33:52 +0000
parents
children f649f6066e4d
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/deploy/osx/deploy.sh	Thu Jan 06 15:33:52 2011 +0000
@@ -0,0 +1,25 @@
+#!/bin/bash
+
+# Execute this from the top-level directory of the project (the one
+# that contains the .app bundle).
+
+app=EasyMercurial
+
+version=`perl -p -e 's/^[^"]*"([^"]*)".*$/$1/' version.h`
+bundleVersion="$version".0
+
+echo
+echo "Writing version $bundleVersion in to bundle."
+echo "(This should be a three-part number: major.minor.point)"
+
+perl -p -e "s/EASYHG_VERSION/$bundleVersion/" deploy/osx/Info.plist \
+    > "$app".app/Contents/Info.plist
+
+echo "Done: check $app.app for sanity please"
+
+echo
+echo "Making dmg..."
+
+hdiutil create -srcfolder "$app".app "$app"-"$version".dmg -volname "$app"-"$version"
+
+echo "Done"