From 9f60c5f6c4937766e1c9e78cbba851f588ad18aa Mon Sep 17 00:00:00 2001 From: Anatoli Babenia Date: Tue, 14 Jan 2025 09:17:57 +0300 Subject: [PATCH] Use `command -v ` instead of `which` Because `which` may not be available. --- installer.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/installer.sh b/installer.sh index 2b2d5306..bc6686f3 100755 --- a/installer.sh +++ b/installer.sh @@ -107,7 +107,7 @@ _install_pkgx() { rm -r "$tmpdir" - if [ "$(command which pkgx)" != /usr/local/bin/pkgx ]; then + if [ "$(command -v pkgx)" != /usr/local/bin/pkgx ]; then echo "warning: active pkgx is not /usr/local/bin/pkgx" >&2 export PATH="/usr/local/bin:$PATH" # so we can exec if required fi