Skip to content

Commit

Permalink
Replace which command ( non standard) with command -v builtin
Browse files Browse the repository at this point in the history
Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
  • Loading branch information
humblec committed May 17, 2021
1 parent 7b96bea commit 48e71f0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion verify-shellcheck.sh
Expand Up @@ -84,7 +84,7 @@ done < <(find . -name "*.sh" \
# detect if the host machine has the required shellcheck version installed
# if so, we will use that instead.
HAVE_SHELLCHECK=false
if which shellcheck &>/dev/null; then
if command -v shellcheck &>/dev/null; then
detected_version="$(shellcheck --version | grep 'version: .*')"
if [[ "${detected_version}" = "version: ${SHELLCHECK_VERSION}" ]]; then
HAVE_SHELLCHECK=true
Expand Down

0 comments on commit 48e71f0

Please sign in to comment.