fixes for go-args
This commit is contained in:
parent
7e19f3b9ae
commit
c5f840ec2f
5
argv.go
5
argv.go
|
@ -9,7 +9,6 @@ package main
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"go.wit.com/dev/alexflint/arg"
|
|
||||||
"go.wit.com/log"
|
"go.wit.com/log"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -21,12 +20,14 @@ type args struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (args) Version() string {
|
func (args) Version() string {
|
||||||
return "zood " + VERSION + " Built on: " + BUILDTIME
|
return "zookeeper " + VERSION + " Built on: " + BUILDTIME
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
func init() {
|
func init() {
|
||||||
arg.MustParse(&argv)
|
arg.MustParse(&argv)
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
func (a args) Description() string {
|
func (a args) Description() string {
|
||||||
return `
|
return `
|
||||||
|
|
2
main.go
2
main.go
|
@ -9,6 +9,7 @@ import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"go.wit.com/dev/alexflint/arg"
|
"go.wit.com/dev/alexflint/arg"
|
||||||
|
"go.wit.com/gui"
|
||||||
"go.wit.com/lib/protobuf/zoopb"
|
"go.wit.com/lib/protobuf/zoopb"
|
||||||
"go.wit.com/log"
|
"go.wit.com/log"
|
||||||
)
|
)
|
||||||
|
@ -21,6 +22,7 @@ var resources embed.FS
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
var pp *arg.Parser
|
var pp *arg.Parser
|
||||||
|
gui.InitArg()
|
||||||
pp = arg.MustParse(&argv)
|
pp = arg.MustParse(&argv)
|
||||||
|
|
||||||
if pp == nil {
|
if pp == nil {
|
||||||
|
|
Loading…
Reference in New Issue