X-Git-Url: https://arthur.barton.de/gitweb/?p=appify.git;a=blobdiff_plain;f=appify.sh;h=a7db78620f05e361fbf60059f9aff50c0beaf282;hp=537b74c8080422d8f4cc1f1924d8d183863b029f;hb=f23850b38ed51ecae95beda6fe796fdb92124ba1;hpb=4a927741fca735d0597999cd1952dcc13580db68 diff --git a/appify.sh b/appify.sh index 537b74c..a7db786 100755 --- a/appify.sh +++ b/appify.sh @@ -1,7 +1,9 @@ #!/bin/bash # -# appify -- convert your non-interactive shell script into a Mac OS X application +# appify -- convert non-interactive shell script into Mac OS X applications # Copyright (C) 2010 Adam Backstrom +# Copyright (C) 2015 Alexander Barton +# # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or @@ -45,8 +47,13 @@ TARGET=$2 BASENAME=`basename "$SCRIPT"` +if [ ! -r "$SCRIPT" ]; then + echo "$SCRIPT isn't readable!" 1>&2 + exit 3 +fi + if [ -e "$TARGET" ]; then - echo "$TARGET exists, exiting" 1>&2 + echo "$TARGET exists!" 1>&2 exit 3 fi