From d16f0312e885ddb5af2eee9102e6075303cd762f Mon Sep 17 00:00:00 2001 From: Dave Hulbert Date: Wed, 29 Nov 2023 18:41:25 +0000 Subject: [PATCH] Use `builtin` when calling `which`. Fixes #18 --- clipea/clipea.zsh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/clipea/clipea.zsh b/clipea/clipea.zsh index c48542b..f883b68 100755 --- a/clipea/clipea.zsh +++ b/clipea/clipea.zsh @@ -14,12 +14,12 @@ CLIPEA_SCRIPT_DIR=$(dirname $(readlink -f ${(%):-%x})) CLIPEA_PYTHON= -CLIPEA_PATH=$(which clipea) +CLIPEA_PATH=$(builtin which clipea) # Run clipea from the current dir if possible if [[ -f $CLIPEA_SCRIPT_DIR/__main__.py ]]; then CLIPEA_PATH=$CLIPEA_SCRIPT_DIR - CLIPEA_PYTHON="$(which python3 || which python)" + CLIPEA_PYTHON="$(builtin which python3 || builtin which python)" fi # Execute clipea with an environment variable