Add release into startup
This commit is contained in:
parent
936b64f2a3
commit
822ac8ec68
|
|
@ -31,6 +31,8 @@ builds:
|
|||
- goos: windows # Does anyone use Windows on arm64?
|
||||
goarch: arm64
|
||||
|
||||
ldflags:
|
||||
- -s -w -X main.version={{.Version}} -X main.commit={{.Commit}} -X main.date={{ .CommitDate }}
|
||||
|
||||
checksum:
|
||||
name_template: 'checksums.txt'
|
||||
|
|
|
|||
|
|
@ -14,10 +14,18 @@ import (
|
|||
|
||||
var (
|
||||
cfg *config.Config
|
||||
version = "dev"
|
||||
commit = "nocommit"
|
||||
date = "nodate"
|
||||
)
|
||||
|
||||
func init() {
|
||||
log.Info("OliveTin initializing")
|
||||
log.WithFields(log.Fields{
|
||||
"version": version,
|
||||
"commit": commit,
|
||||
"date": date,
|
||||
}).Info("OliveTin initializing")
|
||||
|
||||
log.SetLevel(log.DebugLevel) // Default to debug, to catch cfg issues
|
||||
|
||||
viper.AutomaticEnv()
|
||||
|
|
|
|||
Loading…
Reference in New Issue