From c88746629be0e8d330bd51a59253a8c037215a0f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20=C5=81uczy=C5=84ski?= Date: Sat, 13 Nov 2021 10:33:41 +0100 Subject: [PATCH] zsh plugin: fix ZLUA_EXEC check Previous check required full path (even if value was available in PATH) --- z.lua.plugin.zsh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/z.lua.plugin.zsh b/z.lua.plugin.zsh index 4383419..971fa72 100644 --- a/z.lua.plugin.zsh +++ b/z.lua.plugin.zsh @@ -2,7 +2,10 @@ ZLUA_SCRIPT="${0:A:h}/z.lua" -[[ -n "$ZLUA_EXEC" ]] && [[ ! -x "$ZLUA_EXEC" ]] && ZLUA_EXEC="" +if [[ -n "$ZLUA_EXEC" ]] && ! which "$ZLUA_EXEC" &>/dev/null; then + echo "$ZLUA_EXEC not found" + ZLUA_EXEC="" +fi # search lua executable if [[ -z "$ZLUA_EXEC" ]]; then