From 37a05500bffbf54491080fa587a2300b6c35c971 Mon Sep 17 00:00:00 2001 From: "Hektor Misplon (aider)" Date: Fri, 9 May 2025 22:22:01 +0200 Subject: [PATCH] refactor: use explicit executable check for zk command --- .bin/setup-zk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.bin/setup-zk b/.bin/setup-zk index 3269333..35a6df8 100755 --- a/.bin/setup-zk +++ b/.bin/setup-zk @@ -11,10 +11,10 @@ read -p "Would you like open your zettelkasten? [y/N] " -n 1 -r echo if [[ $REPLY =~ ^[Yy]$ ]]; then - if command -v zk &>/dev/null; then + if [ -x "$(command -v zk)" ]; then zk else - echo "Error: 'zk' command not found" + echo "Error: 'zk' command not found or not executable" exit 1 fi fi