Files
BitSrunLoginGo/internal/global/flags.go
2023-06-01 18:26:09 +08:00

19 lines
291 B
Go

package global
import (
"flag"
)
var Flags struct {
//配置文件路径
Path string
Interface string
}
func initFlags() {
flag.StringVar(&Flags.Path, "config", "Config.yaml", "config path")
flag.StringVar(&Flags.Interface, "interface", "", "specify the eth name")
flag.Parse()
}