Skip to content

Commit bb5bfac

Browse files
abitrollymxcl
authored andcommitted
Use command -v instead of which
Because `which` may not be available.
1 parent 0514229 commit bb5bfac

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

installer.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ _install_pkgx() {
107107

108108
rm -r "$tmpdir"
109109

110-
if [ "$(command which pkgx)" != /usr/local/bin/pkgx ]; then
110+
if [ "$(command -v pkgx)" != /usr/local/bin/pkgx ]; then
111111
echo "warning: active pkgx is not /usr/local/bin/pkgx" >&2
112112
export PATH="/usr/local/bin:$PATH" # so we can exec if required
113113
fi

0 commit comments

Comments
 (0)