chore: 并入 iotlcm-upstream-proxy 历史到 upstream-proxy/(原提交 44209ec)
This commit is contained in:
@@ -0,0 +1,51 @@
|
||||
// package version
|
||||
// @Link https://github.com/xiujiecn/xiu-admin
|
||||
// @Copyright Copyright (c) 2025 LiXiujie
|
||||
// @Author Lxj <xxx@example.com>
|
||||
// @License https://github.com/xiujiecn/xiu-admin/blob/master/LICENSE
|
||||
package version
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
|
||||
"github.com/gogf/gf/v2/frame/g"
|
||||
)
|
||||
|
||||
var (
|
||||
BuildTime string
|
||||
BuildVersion string
|
||||
CommitID string
|
||||
)
|
||||
|
||||
func ShowLogo(ctx context.Context, buildVersion, buildTime, commitID string) {
|
||||
BuildVersion = buildVersion
|
||||
BuildTime = buildTime
|
||||
CommitID = commitID
|
||||
//版本号
|
||||
|
||||
g.Log().Notice(ctx, `
|
||||
|
||||
██╗██╗███████╗ ██╗ ██████╗ ████████╗
|
||||
██║██║██╔════╝ ██║██╔═══██╗╚══██╔══╝
|
||||
██║██║█████╗ ██║██║ ██║ ██║
|
||||
██ ██║██║██╔══╝ ██║██║ ██║ ██║
|
||||
╚█████╔╝██║███████╗ ██║╚██████╔╝ ██║
|
||||
╚════╝ ╚═╝╚══════╝ ╚═╝ ╚═════╝ ╚═╝
|
||||
|
||||
`)
|
||||
|
||||
g.Log().Notice(ctx, "Version :", buildVersion)
|
||||
g.Log().Notice(ctx, "BuildTime :", buildTime)
|
||||
g.Log().Notice(ctx, "CommitID :", commitID)
|
||||
g.Log().Notice(ctx, "Copyright:", "2026 The iotLCM Authors")
|
||||
|
||||
fmt.Println("Version :", buildVersion)
|
||||
fmt.Println("BuildTime :", buildTime)
|
||||
fmt.Println("CommitID :", commitID)
|
||||
fmt.Println("Copyright:", "2026 The iotLCM Authors")
|
||||
}
|
||||
|
||||
func AppName(ctx context.Context) string {
|
||||
return g.Cfg().MustGet(ctx, "system.appName", "IotLCM").String()
|
||||
}
|
||||
Reference in New Issue
Block a user