structure changes

This commit is contained in:
2026-01-06 15:45:56 -05:00
parent ef53232fca
commit f3114b38a8
14 changed files with 123 additions and 95 deletions

View File

@@ -14,16 +14,60 @@ site:h2("Fes")
site:muted("fes is a lightweight, static, and optionated microframework.")
site:h2("Development")
site:p("You can " .. std.external("https://git.vxserver.dev/fSD/fes", "browse") .. " its source code or get a copy using the following command:")
site:p("You can " ..
std.external("https://git.vxserver.dev/fSD/fes", "browse") ..
" its source code or get a copy using the following command:")
site:code("git clone https://git.vxserver.dev/fSD/fes")
site:h2("Docker")
site:p("You can deploy websites using the " .. std.external("https://git.vxserver.dev/fSD/-/packages/container/fes/latest", "docker") .. " image:")
site:p("You can deploy websites using the " ..
std.external("https://git.vxserver.dev/fSD/-/packages/container/fes/latest", "docker") .. " image:")
site:code("docker pull git.vxserver.dev/fsd/fes:latest")
local tars = u.ls("archive")
local function parseVersion(pkg)
local version = pkg:match("-(.+)$")
local parts = {}
for n in version:gmatch("%d+") do
parts[#parts + 1] = tonumber(n)
end
return parts
end
local function isNewer(a, b)
local va, vb = parseVersion(a), parseVersion(b)
local len = math.max(#va, #vb)
for i = 1, len do
local na, nb = va[i] or 0, vb[i] or 0
if na ~= nb then
return na > nb
end
end
return false
end
local function latestRelease(packages, name)
local latest = nil
local prefix = "^" .. name .. "%-"
for _, pkg in ipairs(packages) do
if pkg:match(prefix) then
if not latest or isNewer(pkg, latest) then
latest = pkg
end
end
end
return latest
end
local latest = latestRelease(tars, "fes")
site:h2("Download")
site:ul {
std.p(std.a("/archive/fes/fes-0.3.0.tar.gz", "fes-0.3.0") .. " (2026-04-1)"),
std.p(std.a("/archive/" .. latest, latest) .. " (2026-04-1)"),
std.a("/archive/fes", "Looking for specific version?")
}