From: ceriel Date: Tue, 19 Apr 1988 16:57:19 +0000 (+0000) Subject: Added check that script is started from proper directory X-Git-Tag: release-5-5~3378 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=0768c1454476886b0a8b23658d1dfefba71a5d6a;p=ack.git Added check that script is started from proper directory --- diff --git a/first/first b/first/first index 3cb055525..1b07bca8a 100755 --- a/first/first +++ b/first/first @@ -1,3 +1,13 @@ +: check that the script is started from the "first" directory +p=`pwd` +case `basename $p` in +first) + ;; +*) + echo "this script must be started from the 'first' directory" + exit 3 + ;; +esac : check $PATH first if sh ckpath then :