The wiki has moved!

Visit the new wiki at stationeers-wiki.com The old wiki here at legacy.stationeers-wiki.com will sunset eventually.

Edits made after the 7th of March 6PM EST were NOT carried over to the new server as previously announced right here in this box.

 Actions

Module

LatestVersion

From Unofficial Stationeers Wiki

Revision as of 03:49, 18 October 2025 by Claimer (talk | contribs) (hope for automate system for version for main page.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Documentation for this module may be created at Module:LatestVersion/doc

local p = {}

function p.getVersion(frame)
    local title = mw.title.new('Updates_Overview')
    if not title or not title.exists then
        return "Error: Updates_Overview not found"
    end
    
    local content = title:getContent()
    
    -- Search for first version in format v0.2.xxxx.xxxxx
    local version = string.match(content, "v%d+%.%d+%.%d+%.%d+")
    
    return version or "Version not found"
end

return p