Files
Sillyv2/core/init.go
T
2021-09-17 19:39:03 +08:00

24 lines
405 B
Go

package core
import (
"os"
"time"
)
var Duration = time.Duration(sillyGirl.GetInt("duration", 5)) * time.Second
func init() {
killp()
for _, arg := range os.Args {
if arg == "-d" {
initStore()
Daemon()
}
}
initStore()
ReadYaml(ExecPath+"/conf/", &Config, "https://raw.githubusercontent.com/cdle/sillyGirl/main/conf/demo_config.yaml")
InitReplies()
initToHandleMessage()
initSys()
}