package main import ( _ "embed" "log" "strings" ) //go:embed VERSION.txt var version string func init() { if version == "" { log.Fatal("Bad build: No version string embedded.") } version = strings.Trim(version, "\n") }