From a29ff9acd24ab3b6fc2012cf6da664909afae618 Mon Sep 17 00:00:00 2001 From: luisgulo Date: Thu, 6 Nov 2025 18:02:05 +0100 Subject: YQ_BIN in shflow-check --- core/utils/shflow-check.sh | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'core/utils/shflow-check.sh') diff --git a/core/utils/shflow-check.sh b/core/utils/shflow-check.sh index 130eca0..d026875 100755 --- a/core/utils/shflow-check.sh +++ b/core/utils/shflow-check.sh @@ -20,7 +20,17 @@ if ! declare -f render_msg &>/dev/null; then [[ -f "$COMMON_LIB" ]] && source "$COMMON_LIB" fi -GLOBAL_TOOLS=("bash" "ssh" "scp" "git" "curl" "jq" "yq" "gpg") +# 🔧 yq segun arquitectura +ARCH=$(uname -m) +case "$ARCH" in + x86_64) YQ_BIN="$PROJECT_ROOT/core/utils/yq_linux_amd64" ;; + i686|i386) YQ_BIN="$PROJECT_ROOT/core/utils/yq_linux_386" ;; + aarch64) YQ_BIN="$PROJECT_ROOT/core/utils/yq_linux_arm64" ;; + armv7l|armv6l) YQ_BIN="$PROJECT_ROOT/core/utils/yq_linux_arm" ;; + *) echo "❌ Arquitectura no soportada: $ARCH"; exit 1 ;; +esac + +GLOBAL_TOOLS=("bash" "ssh" "scp" "git" "curl" "jq" "$YQ_BIN" "gpg") REQUIRED_PATHS=( "$PROJECT_ROOT/core/modules" @@ -47,6 +57,7 @@ check_global_tools() { echo "$(render_msg "${tr[tool_missing]}" "tool=$tool")" missing=1 else + tool=$(basename $tool) echo "$(render_msg "${tr[tool_ok]}" "tool=$tool")" fi done -- cgit v1.2.3