mirror of
https://bitbucket.org/s_l_teichmann/mtsatellite
synced 2025-06-28 06:12:08 +02:00
Unified handling of printing versions of programs (--version). Setting version to 0.5
This commit is contained in:
@ -31,6 +31,7 @@ func main() {
|
||||
updateHosts string
|
||||
websockets bool
|
||||
playersFIFO string
|
||||
version bool
|
||||
)
|
||||
flag.IntVar(&webPort, "web-port", 8808, "port of the web server")
|
||||
flag.IntVar(&webPort, "p", 8808, "port of the web server (shorthand)")
|
||||
@ -63,9 +64,14 @@ func main() {
|
||||
flag.BoolVar(&websockets, "ws", false, "Forward tile changes to clients via websockets (shorthand).")
|
||||
flag.StringVar(&playersFIFO, "players", "", "Path to FIFO file to read active players from.")
|
||||
flag.StringVar(&playersFIFO, "ps", "", "Path to FIFO file to read active players from (shorthand).")
|
||||
flag.BoolVar(&version, "version", false, "Print version and exit.")
|
||||
|
||||
flag.Parse()
|
||||
|
||||
if version {
|
||||
common.PrintVersionAndExit()
|
||||
}
|
||||
|
||||
router := mux.NewRouter()
|
||||
|
||||
subBaseLine := newSubBaseLine(mapDir)
|
||||
|
Reference in New Issue
Block a user