gf/.example/os/glog/glog_category.go

17 lines
310 B
Go
Raw Normal View History

2018-08-24 23:41:58 +08:00
package main
import (
2019-07-29 21:01:19 +08:00
"github.com/gogf/gf/frame/g"
"github.com/gogf/gf/os/gfile"
"github.com/gogf/gf/os/glog"
2018-08-24 23:41:58 +08:00
)
func main() {
2019-04-03 00:03:46 +08:00
path := "/tmp/glog-cat"
glog.SetPath(path)
2019-06-01 11:01:57 +08:00
glog.Stdout(false).Cat("cat1").Cat("cat2").Println("test")
2019-04-03 00:03:46 +08:00
list, err := gfile.ScanDir(path, "*", true)
g.Dump(err)
g.Dump(list)
2018-08-24 23:41:58 +08:00
}