diff --git a/run_universal_config.sh b/run_universal_config.sh index d868ae8..6ed9f20 100644 --- a/run_universal_config.sh +++ b/run_universal_config.sh @@ -1,8 +1,11 @@ #!/bin/sh -VERSION=$(ubus call system board | jsonfilter -e '@.release.description') +DESCRIPTION=$(ubus call system board | jsonfilter -e '@.release.description') +VERSION=$(ubus call system board | jsonfilter -e '@.release.version') +findKey="Routerich" +findVersion="24.10.2" -if echo "$VERSION" | grep -qi 'RouteRich'; then +if echo "$DESCRIPTION" | grep -qi -- "$findKey" && printf '%s\n%s\n' "$findVersion" "$VERSION" | sort -V | tail -n1 | grep -qx -- "$VERSION"; then printf "\033[32;1mThis new firmware. Running new scprit...\033[0m\n" wget --no-check-certificate -O /tmp/universal_config_new_podkop.sh https://raw.githubusercontent.com/routerich/RouterichAX3000_configs/refs/heads/beta_alt_test/universal_config_new_podkop.sh && chmod +x /tmp/universal_config_new_podkop.sh && /tmp/universal_config_new_podkop.sh $1 $2 else