29 lines
503 B
Go
29 lines
503 B
Go
package main
|
|
|
|
/*
|
|
this enables command line options from other packages like 'gui' and 'log'
|
|
*/
|
|
|
|
import (
|
|
"go.wit.com/dev/alexflint/arg"
|
|
"go.wit.com/lib/debugger"
|
|
"go.wit.com/log"
|
|
)
|
|
|
|
var argGui ArgsGui
|
|
|
|
// This struct can be used with the go-arg package
|
|
type ArgsGui struct {
|
|
Test bool `arg:"--test" help:"enable all logging"`
|
|
}
|
|
|
|
func init() {
|
|
arg.MustParse(&argGui)
|
|
|
|
if debugger.ArgDebug() {
|
|
log.Log(true, "INIT() gui debug == true")
|
|
} else {
|
|
log.Log(true, "INIT() gui debug == false")
|
|
}
|
|
}
|