From: Paul Eggleton Date: Tue, 21 Apr 2015 13:01:56 +0000 (+0100) Subject: mkefidisk.sh: be more explicit with device error X-Git-Tag: 2015-10~2046 X-Git-Url: https://code.ossystems.io/gitweb?a=commitdiff_plain;h=92b58e1c789ee412d936285144e8e549c99ff979;p=openembedded-core.git mkefidisk.sh: be more explicit with device error * Specify whether the device can't be found or can't be written to * Give a hint to use sudo Signed-off-by: Paul Eggleton Signed-off-by: Richard Purdie --- diff --git a/scripts/contrib/mkefidisk.sh b/scripts/contrib/mkefidisk.sh index d6bc965137..55f72b0f54 100755 --- a/scripts/contrib/mkefidisk.sh +++ b/scripts/contrib/mkefidisk.sh @@ -173,7 +173,11 @@ fi if [ ! -w "$DEVICE" ]; then usage - die "Device $DEVICE does not exist or is not writable" + if [ ! -e "${DEVICE}" ] ; then + die "Device $DEVICE cannot be found" + else + die "Device $DEVICE is not writable (need to run under sudo?)" + fi fi if [ ! -e "$HDDIMG" ]; then