mirror of
https://github.com/BaaRai/ARTEX.git
synced 2026-11-19 14:40:53 +08:00
feat: 顶栏显示后端应用版本号
后端 /api/health 返回 BuildVersion(由 ldflags 注入的 main.version), 前端顶栏设置按钮左侧展示 v<版本>。
This commit is contained in:
@@ -48,6 +48,10 @@ func main() {
|
||||
)
|
||||
flag.Parse()
|
||||
|
||||
// hand the build version to the server package so GET /api/health can report it
|
||||
// to the frontend top bar.
|
||||
server.BuildVersion = version
|
||||
|
||||
printBanner(*addr)
|
||||
|
||||
// capture backend logs into the in-memory sink (still to stderr) so the /logs
|
||||
|
||||
Reference in New Issue
Block a user