Adding the version in the generated binary
This commit is contained in:
@@ -11,6 +11,14 @@ import (
|
||||
"github.com/dimiro1/ipe/ipe"
|
||||
)
|
||||
|
||||
// These variables are generated by the linker
|
||||
// please see the makefile for mor information.
|
||||
var (
|
||||
version string = "version"
|
||||
buildstamp string = "buildstamp"
|
||||
githash string = "githash"
|
||||
)
|
||||
|
||||
// Main function, initialize the system
|
||||
func main() {
|
||||
var filename = flag.String("config", "config.json", "Config file location")
|
||||
@@ -39,5 +47,6 @@ Y8P
|
||||
`)
|
||||
fmt.Println("\033[0m")
|
||||
fmt.Println("\033[32mWelcome to Ipê - Yet another Pusher server clone (https://github.com/dimiro1/ipe)\033[0m")
|
||||
fmt.Printf("\033[32mVersion %s+%s.git.%s\033[0m\n", version, buildstamp, githash)
|
||||
fmt.Println("\033[33mBy: Claudemiro Alves Feitosa Neto <[email protected]>\033[0m")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user