Unified handling of printing versions of programs (--version). Setting version to 0.5

This commit is contained in:
Sascha L. Teichmann
2015-07-26 22:04:16 +02:00
parent f6b5f9ce97
commit 62a53dc26b
6 changed files with 44 additions and 3 deletions

17
common/version.go Normal file
View File

@ -0,0 +1,17 @@
// Copyright 2014 by Sascha L. Teichmann
// Use of this source code is governed by the MIT license
// that can be found in the LICENSE file.
package common
import (
"fmt"
"os"
)
const MTSatelliteVersion = "0.5"
func PrintVersionAndExit() {
fmt.Printf("Version: %s\n", MTSatelliteVersion)
os.Exit(0)
}