From bdd0e9213f6b96c7c3c7b2d677065d6c669fcd1d Mon Sep 17 00:00:00 2001 From: Codevalve <6092+codevalve@users.noreply.github.com> Date: Thu, 28 Nov 2024 20:12:33 -0600 Subject: [PATCH] fix(scripts): replace process substitution with for loop for better shell compatibility --- src/core/common.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/core/common.sh b/src/core/common.sh index 2d2870f..fd5e4b6 100755 --- a/src/core/common.sh +++ b/src/core/common.sh @@ -17,11 +17,12 @@ check_required_tools() { local config_file="$1" local missing_tools=() - while IFS= read -r tool; do + # Get required tools and check each one + for tool in $(yq eval '.tools.required[]' "$config_file"); do if ! command_exists "$tool"; then missing_tools+=("$tool") fi - done < <(yq eval '.tools.required[]' "$config_file") + done if [ ${#missing_tools[@]} -ne 0 ]; then echo -e "${RED}Missing required tools:${NC}"