From 7fa5aa971796c4a5154ec1206271b7a930ad95c7 Mon Sep 17 00:00:00 2001 From: CodeRoK7 <58553260+CodeRoK7@users.noreply.github.com> Date: Tue, 26 Aug 2025 06:01:19 +0000 Subject: [PATCH] Fix check version sing-box --- universal_config.sh | 4 ++-- universal_config_new_podkop.sh | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/universal_config.sh b/universal_config.sh index 19f1f33..137b009 100644 --- a/universal_config.sh +++ b/universal_config.sh @@ -487,7 +487,7 @@ checkPackageAndInstall "youtubeUnblock" "1" manage_package "podkop" "enable" "stop" PACKAGE="sing-box" -REQUIRED_VERSION="1.11.15-1" +REQUIRED_VERSION="1.11.15" INSTALLED_VERSION=$(opkg list-installed | grep "^$PACKAGE" | cut -d ' ' -f 3) if [ -n "$INSTALLED_VERSION" ] && [ "$INSTALLED_VERSION" != "$REQUIRED_VERSION" ]; then @@ -496,7 +496,7 @@ if [ -n "$INSTALLED_VERSION" ] && [ "$INSTALLED_VERSION" != "$REQUIRED_VERSION" fi INSTALLED_VERSION=$(opkg list-installed | grep "^$PACKAGE") -if [ -n "$INSTALLED_VERSION" ]; then +if [ -z "$INSTALLED_VERSION" ]; then PACK_NAME="sing-box" AWG_DIR="/tmp/$PACK_NAME" SINGBOX_FILENAME="sing-box_1.11.15_openwrt_aarch64_cortex-a53.ipk" diff --git a/universal_config_new_podkop.sh b/universal_config_new_podkop.sh index 5d1b8bd..c568948 100644 --- a/universal_config_new_podkop.sh +++ b/universal_config_new_podkop.sh @@ -497,7 +497,7 @@ checkPackageAndInstall "youtubeUnblock" "1" manage_package "podkop" "enable" "stop" PACKAGE="sing-box" -REQUIRED_VERSION="1.11.15-1" +REQUIRED_VERSION="1.11.15" INSTALLED_VERSION=$(opkg list-installed | grep "^$PACKAGE" | cut -d ' ' -f 3) if [ -n "$INSTALLED_VERSION" ] && [ "$INSTALLED_VERSION" != "$REQUIRED_VERSION" ]; then @@ -506,7 +506,7 @@ if [ -n "$INSTALLED_VERSION" ] && [ "$INSTALLED_VERSION" != "$REQUIRED_VERSION" fi INSTALLED_VERSION=$(opkg list-installed | grep "^$PACKAGE") -if [ -n "$INSTALLED_VERSION" ]; then +if [ -z "$INSTALLED_VERSION" ]; then PACK_NAME="sing-box" AWG_DIR="/tmp/$PACK_NAME" SINGBOX_FILENAME="sing-box_1.11.15_openwrt_aarch64_cortex-a53.ipk"