From ee387b79e1bad478f2ae96c568e08fc503887115 Mon Sep 17 00:00:00 2001 From: Alex X Date: Thu, 9 May 2024 08:21:19 +0300 Subject: [PATCH] Update version output --- internal/app/app.go | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/internal/app/app.go b/internal/app/app.go index 79354a04..bc44a16f 100644 --- a/internal/app/app.go +++ b/internal/app/app.go @@ -36,7 +36,7 @@ func Init() { flag.Parse() if version { - fmt.Println("Current version:", Version) + fmt.Printf("go2rtc version %s %s/%s\n", Version, runtime.GOOS, runtime.GOARCH) os.Exit(0) } @@ -99,7 +99,13 @@ func Init() { modules = cfg.Mod - log.Info().Msgf("go2rtc version %s %s/%s", Version, runtime.GOOS, runtime.GOARCH) + platform := fmt.Sprintf("%s/%s", runtime.GOOS, runtime.GOARCH) + log.Info().Str("version", Version).Str("platform", platform).Msg("go2rtc") + log.Debug().Str("version", runtime.Version()).Msg("build") + + if ConfigPath != "" { + log.Info().Str("path", ConfigPath).Msg("config") + } migrateStore() }