From 2c5a59bbac97d79c7d860103b6763b603d2636dc Mon Sep 17 00:00:00 2001 From: bryan Date: Thu, 30 Jul 2026 16:49:46 -0400 Subject: [PATCH] Make rerun() more robust if curl is unavailable --- installJRMC | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/installJRMC b/installJRMC index 7a66cb5..b21ddae 100755 --- a/installJRMC +++ b/installJRMC @@ -2268,8 +2268,12 @@ rerun() { debug "${FUNCNAME[0]}()" "$@" if ((SCRIPT_IS_PIPED)); then # Re-download and execute if script was piped - curl -fsSL "$SCRIPT_URL" | bash -s -- "$@" "--no-update" - exit $? + if command -v curl &>/dev/null || install_package curl; then + curl -fsSL "$SCRIPT_URL" | bash -s -- "$@" "--no-update" + else + bash -s -- "$@" "--no-update" + fi + exit $? # exit parent script with same exit code else exec bash "$SCRIPT_PATH" "$@" "--no-update" fi