In minimal environments (e.g. Fedora container image) 'which' is not installed by default. To avoid the need to install an additional dependency, use 'command -v', which also does the trick and is a shell builtin. Signed-off-by: Ondrej Mosnacek <omosnace@xxxxxxxxxx> --- tools/check-syntax | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/check-syntax b/tools/check-syntax index 0ca79e2..2115a79 100755 --- a/tools/check-syntax +++ b/tools/check-syntax @@ -27,7 +27,7 @@ CHK_PERL_EXCLUDE="" # function verify_deps() { [[ -z "$1" ]] && return - if ! which "$1" >& /dev/null; then + if ! command -v "$1" >& /dev/null; then echo "error: install \"$1\" and include it in your \$PATH" exit 1 fi -- 2.29.2