commit 6fd3d07b4b4064e3df1a7292d7655e90b0eb1297 parent 553006c7e59542c9ae2ebc96f756ae1d22752881 Author: ThomasV <thomasv@electrum.org> Date: Tue, 27 Mar 2018 17:31:44 +0200 osx builds: use version number from Info.plist Diffstat:
M | contrib/build-osx/package.sh | | | 11 | ++++++++++- |
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/contrib/build-osx/package.sh b/contrib/build-osx/package.sh @@ -55,6 +55,11 @@ fi ${genisoimage} -version || fail "Unable to install genisoimage" dmg -|| fail "Unable to install libdmg" +plist=$1/Contents/Info.plist +test -f "$plist" || fail "Info.plist not found" +VERSION=$(grep -1 ShortVersionString $plist |tail -1|gawk 'match($0, /<string>(.*)<\/string>/, a) {print a[1]}') +echo $VERSION + rm -rf /tmp/electrum-macos/image > /dev/null 2>&1 mkdir /tmp/electrum-macos/image/ cp -r $1 /tmp/electrum-macos/image/ @@ -76,4 +81,8 @@ ${genisoimage} \ -o Electrum_uncompressed.dmg \ /tmp/electrum-macos/image || fail "Unable to create uncompressed dmg" -dmg dmg Electrum_uncompressed.dmg Electrum.dmg || fail "Unable to create compressed dmg" +dmg dmg Electrum_uncompressed.dmg electrum-$VERSION.dmg || fail "Unable to create compressed dmg" +rm Electrum_uncompressed.dmg + +echo "Done." +md5sum electrum-$VERSION.dmg