From 353b87956c7e3275c3babdc8f24466a56016f6e3 Mon Sep 17 00:00:00 2001 From: Benjamin Jurk <106487517+bnjmnjrk@users.noreply.github.com> Date: Mon, 11 Aug 2025 12:50:41 +0000 Subject: [PATCH] add support for wget as a fallback for downloading bun --- scripts/bun_install.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/bun_install.sh b/scripts/bun_install.sh index 474b00385b2..5e260fa05e5 100644 --- a/scripts/bun_install.sh +++ b/scripts/bun_install.sh @@ -142,8 +142,13 @@ if [[ ! -d $bin_dir ]]; then error "Failed to create install directory \"$bin_dir\"" fi -curl --fail --location --progress-bar --output "$exe.zip" "$bun_uri" || +if command -v curl >/dev/null 2>&1; then + curl --fail --location --progress-bar --output "$exe.zip" "$bun_uri" || error "Failed to download bun from \"$bun_uri\"" +else + wget --quiet --show-progress --output-document="$exe.zip" "$bun_uri" || + error "Failed to download bun from \"$bun_uri\"" +fi unzip -oqd "$bin_dir" "$exe.zip" || error 'Failed to extract bun'