misc: Use bash's command instead of which
Bash has a built-in command, `command`, that will search the path and return the full path to a command if it exists (or an exit code of 1 if it does not), preventing the requirement of the `which` package.
This commit is contained in:
@@ -17,7 +17,7 @@ set -o pipefail
|
||||
|
||||
ROOT=$(dirname "${BASH_SOURCE}")/..
|
||||
|
||||
RUBY=`which ruby 2>/dev/null`
|
||||
RUBY=`command -v ruby 2>/dev/null`
|
||||
if [ -z $RUBY ]; then
|
||||
fail_test "The 'ruby' utility can't be found."
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user