25 lines
472 B
Go
25 lines
472 B
Go
//go:build dev
|
|
|
|
package version
|
|
|
|
import (
|
|
"fmt"
|
|
)
|
|
|
|
// Version ...
|
|
var Version = "0.1.0"
|
|
|
|
// Prerelease such as "dev" (in development), "beta", "rc1", etc.
|
|
var Prerelease = "dev"
|
|
|
|
// Header is the header name used to send the current in http requests.
|
|
const Header = "Weather-Version"
|
|
|
|
// String returns the complete version string, including prerelease
|
|
func String() string {
|
|
if Prerelease != "" {
|
|
return fmt.Sprintf("%s-%s", Version, Prerelease)
|
|
}
|
|
return Version
|
|
}
|