From 0321f71fb082d4ba7cc3056f023d94662b800a80 Mon Sep 17 00:00:00 2001 From: fukiame Date: Sun, 8 Feb 2026 01:26:03 +0700 Subject: [PATCH] just math it i cant logic smh retar Signed-off-by: fukiame --- MBCPApp/parse.sh | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/MBCPApp/parse.sh b/MBCPApp/parse.sh index 22ffc01..9a638b1 100644 --- a/MBCPApp/parse.sh +++ b/MBCPApp/parse.sh @@ -87,10 +87,10 @@ for f in patches/*.sh ; do minminor="$(bb_split "$minver" '.' '1')" minpatch="$(bb_split "$minver" '.' '2')" - ( [ "$(get_mb_ver '0')" -lt "$minmajor" ] || \ - [ "$(get_mb_ver '1')" -lt "$minminor" ] || \ - [ "$(get_mb_ver '2')" -le "$minpatch" ] \ - ) && { + [ "$(( \ + $(get_mb_ver 0) * 10000 + $(get_mb_ver 1) * 100 + $(get_mb_ver 2) ))" -lt \ + "$(( minmajor * 10000 + minminor * 100 + minpatch ))" \ + ] && { info "[parser] skipping [$pname] as current version is lower than patch version clamp" continue ; } } || : @@ -105,10 +105,10 @@ for f in patches/*.sh ; do maxminor="$(bb_split "$maxver" '.' '1')" maxpatch="$(bb_split "$maxver" '.' '2')" - ( [ "$(get_mb_ver '0')" -gt "$maxmajor" ] || \ - [ "$(get_mb_ver '1')" -gt "$maxminor" ] || \ - [ "$(get_mb_ver '2')" -ge "$maxpatch" ] \ - ) && { + [ "$(( \ + $(get_mb_ver 0) * 10000 + $(get_mb_ver 1) * 100 + $(get_mb_ver 2) ))" -gt \ + "$(( maxmajor * 10000 + maxminor * 100 + maxpatch ))" \ + ] && { info "[parser] skipping [$pname] as current version is higher than patch version clamp" continue ; } } || :