mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Add check for existence of 'which' command before proceeding with the script
This commit is contained in:
parent
51a12d1de8
commit
83d495df2e
5
sake
5
sake
@ -9,6 +9,11 @@ Executes a SilverStripe command"
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if ! [ -x "$(command -v which)" ]; then
|
||||||
|
echo "Error: sake requires the 'which' command to operate." >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
# find the silverstripe installation, looking first at sake
|
# find the silverstripe installation, looking first at sake
|
||||||
# bin location, but falling back to current directory
|
# bin location, but falling back to current directory
|
||||||
sakedir=`dirname $0`
|
sakedir=`dirname $0`
|
||||||
|
Loading…
Reference in New Issue
Block a user