mirror of
https://gitee.com/johng/gf.git
synced 2024-12-05 05:37:55 +08:00
20 lines
325 B
Go
20 lines
325 B
Go
package main
|
|
|
|
import (
|
|
"gitee.com/johng/gf/g/os/glog"
|
|
"gitee.com/johng/gf/g/os/gfile"
|
|
"gitee.com/johng/gf/g"
|
|
)
|
|
|
|
// 设置日志输出路径
|
|
func main() {
|
|
path := "/tmp/glog"
|
|
glog.SetPath(path)
|
|
glog.Println("日志内容")
|
|
list, err := gfile.ScanDir(path, "*")
|
|
g.Dump(err)
|
|
g.Dump(list)
|
|
}
|
|
|
|
|