1
0
forked from MTSR/mapserver
This commit is contained in:
Thomas Rudin 2019-01-04 11:00:49 +01:00
parent 4c69837401
commit 013985f76f
4 changed files with 11 additions and 10 deletions

View File

@ -4,10 +4,10 @@ import (
"mapserver/params" "mapserver/params"
) )
func main(){ func main() {
params.Parse() params.Parse()
p := params.Params() p := params.Params()
if (p.Help){ if p.Help {
return return
} }
} }

View File

@ -16,7 +16,7 @@ func Params() ParamsType {
return params return params
} }
func Parse(){ func Parse() {
params := ParamsType{} params := ParamsType{}
flag.StringVar(&(params.Worlddir), "worlddir", "./", "world directory") flag.StringVar(&(params.Worlddir), "worlddir", "./", "world directory")
@ -24,7 +24,7 @@ func Parse(){
flag.BoolVar(&(params.Help), "help", false, "Show help") flag.BoolVar(&(params.Help), "help", false, "Show help")
flag.Parse() flag.Parse()
if (params.Help) { if params.Help {
flag.PrintDefaults() flag.PrintDefaults()
} }
} }

View File

View File

@ -1,3 +1,4 @@
package workdconfig
type WorldConfig struct { type WorldConfig struct {
} }