Files
gitlab.nvim/lua/gitlab/version.lua
Harrison Cramer 3d2828a950 feat!: MAJOR release. Update go to 1.25, and add migration path (#520)
BREAKING CHANGE: This bumps Go and external packages to later versions.
2026-01-30 21:54:00 -05:00

25 lines
586 B
Lua

local M = {}
M.is_go_valid = function()
local go_version = io.popen("go version"):read("*a")
if go_version then
local major, minor, _ = go_version:match("(%d+)%.(%d+)%.?(%d*)")
if major and tonumber(major) >= 1 and tonumber(minor) >= 25 then
return true
else
return false
end
else
return false
end
end
M.check_go_version = function()
local has_version = M.is_go_valid()
if not has_version then
return "Go is not installed, or version is older than 1.25.1. Please reinstall up-to-date Go version: https://go.dev/dl/"
end
end
return M