blob: 3acac53f07bf1354ca2d37120bf3c1787cfc7f63 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
#!/bin/bash
# Ruta de instalación por defecto
SHFLOW_HOME="${SHFLOW_HOME:-$HOME/shflow}"
UTILS_DIR="$SHFLOW_HOME/core/utils"
mkdir -p "$UTILS_DIR"
# Versión de yq a descargar
YQ_VERSION="v4.48.1"
BASE_URL="https://github.com/mikefarah/yq/releases/download/$YQ_VERSION"
# Lista de binarios a descargar
BINARIES=(
"yq_linux_386"
"yq_linux_amd64"
"yq_linux_arm"
"yq_linux_arm64"
)
# Descargar cada binario y darle permisos de ejecución
for binary in "${BINARIES[@]}"; do
url="$BASE_URL/$binary"
target="$UTILS_DIR/$binary"
echo "⬇️ Descargando $url..."
curl -sSL "$url" -o "$target"
chmod +x "$target"
echo "✅ Guardado en $target"
done
echo "🎉 Todos los binarios de yq $YQ_VERSION han sido descargados en $UTILS_DIR"
|