@@ -20,7 +20,7 @@ if session.userinfo and session.userinfo.userid and viewlibrary and viewlibrary.
...
@@ -20,7 +20,7 @@ if session.userinfo and session.userinfo.userid and viewlibrary and viewlibrary.
end
end
-- CHECK SYS RELEASE VERSION
-- CHECK SYS RELEASE VERSION
local check_sysver = string.match(sys.value.version.value, "v%d+.%d+.%d+")
local check_sysver = string.match(sys.value.version.value, "%d+.%d+.%d+")
local major_sysver = string.match(check_sysver, "%d+") -- Parse Major for Upgrade
local major_sysver = string.match(check_sysver, "%d+") -- Parse Major for Upgrade
local minor_sysver = string.gsub(string.match(check_sysver, "%p%d+"), "%D", "") -- Parse Minor for Update
local minor_sysver = string.gsub(string.match(check_sysver, "%p%d+"), "%D", "") -- Parse Minor for Update
local patch_sysver = string.gsub(string.match(check_sysver, ".[^.]*$"), "%D", "") -- Parse Patch for Update
local patch_sysver = string.gsub(string.match(check_sysver, ".[^.]*$"), "%D", "") -- Parse Patch for Update
...
@@ -32,12 +32,12 @@ end
...
@@ -32,12 +32,12 @@ end
local minor_distver = string.gsub(string.match(actual_distver, "%p%d+"), "%D", "") -- Parse Minor for Update
local minor_distver = string.gsub(string.match(actual_distver, "%p%d+"), "%D", "") -- Parse Minor for Update
local patch_distver = string.gsub(string.match(actual_distver, ".[^.]*$"), "%D", "") -- Parse Patch for Fix
local patch_distver = string.gsub(string.match(actual_distver, ".[^.]*$"), "%D", "") -- Parse Patch for Fix
if major_sysver == major_distver and minor_sysver == minor_distver and patch_sysver == patch_distver then
if major_sysver == major_distver and minor_sysver == minor_distver and patch_sysver == patch_distver then
chkres = "<a class='version-link version-ok' href='https://www.alpinelinux.org/releases/' title='🟩 Up to Date' target='_blank'><span class='version-check-ok'>Alpine Linux <span class='version-letter'>" .. check_sysver .. "</span></span></a> | up to date "
chkres = "<a id='alpine-version-link' class='version-link version-ok' href='https://www.alpinelinux.org/releases/' title='🟩 Up to Date' target='_blank'><span class='version-check-ok'>Alpine Linux | <span class='version-letter'>" .. check_sysver .. "</span></span></a> up to date "