diff --git a/build.sh b/build.sh index 5701907..7e74edb 100755 --- a/build.sh +++ b/build.sh @@ -1,6 +1,12 @@ #!/bin/sh + +name="Open Media Library" +tmp="${name}.tmp.dmg" +dmg="${name}.dmg" + tmpdir=`mktemp -d -t oml` -cp -r "Open Media Library.app" $tmpdir/ -hdiutil create -srcfolder "$tmpdir" -volname "Open Media Library" -format UDZO "Open Media Library.tmp.dmg" -hdiutil convert -format UDZO -imagekey zlib-level=9 -o "Open Media Library.dmg" "Open Media Library.tmp.dmg" -rm -rf $tmpdir "Open Media Library.tmp.dmg" +cp -r "${name}.app" $tmpdir/ +rm -rf "$dmg" "$tmp" +hdiutil create -srcfolder "$tmpdir" -volname "$name" -format UDZO "$tmp" +hdiutil convert -format UDZO -imagekey zlib-level=9 -o "$dmg" "$tmp" +rm -rf $tmpdir "$tmp"