From 9cbaf88876ec2c8f522275f7ba60c2f3a557ad39 Mon Sep 17 00:00:00 2001 From: Vittorio Giovara Date: Wed, 10 Jul 2013 23:51:32 +0200 Subject: [PATCH] set internet-enable by default on the dmg --- create-dmg | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/create-dmg b/create-dmg index cf74aa1..b581913 100755 --- a/create-dmg +++ b/create-dmg @@ -40,6 +40,8 @@ function usage() { echo " make a drop link to Applications, at location x,y" echo " --eula eula_file" echo " attach a license file to the dmg" + echo " --no-internet-enable" + echo " disable automatic mount©" echo " --version show tool version number" echo " -h, --help display this help" exit 0 @@ -96,6 +98,9 @@ while test "${1:0:1}" = "-"; do --eula) EULA_RSRC=$2 shift; shift;; + --no-internet-enable) + NOINTERNET=1 + shift;; -*) echo "Unknown option $1. Run with --help for help." exit 1;; @@ -206,5 +211,11 @@ if [ ! -z "${EULA_RSRC}" -a "${EULA_RSRC}" != "-null-" ]; then "${AUX_PATH}/dmg-license.py" "${DMG_DIR}/${DMG_NAME}" "${EULA_RSRC}" fi +if [ ! -z "${NOINTERNET}" -a "${NOINTERNET}" == 1 ]; then + echo "not setting 'internet-enable' on the dmg" +else + hdiutil internet-enable -yes "${DMG_DIR}/${DMG_NAME}" +fi + echo "Disk image done" exit 0