Tobias von Dewitz 75fda08e43 added periodic reconnect to nats | 6 anos atrás | |
---|---|---|
.. | ||
ratelimiter | 6 anos atrás | |
util | 6 anos atrás | |
watch | 6 anos atrás | |
winfile | 6 anos atrás | |
CHANGES.md | 6 anos atrás | |
Dockerfile | 6 anos atrás | |
LICENSE.txt | 6 anos atrás | |
Makefile | 6 anos atrás | |
README.md | 6 anos atrás | |
appveyor.yml | 6 anos atrás | |
tail.go | 6 anos atrás | |
tail_posix.go | 6 anos atrás | |
tail_windows.go | 6 anos atrás |
A Go package striving to emulate the features of the BSD tail
program.
t, err := tail.TailFile("/var/log/nginx.log", tail.Config{Follow: true})
for line := range t.Lines {
fmt.Println(line.Text)
}
See API documentation.
Tail comes with full support for truncation/move detection as it is designed to work with log rotation tools.
go get github.com/hpcloud/tail/...
This package needs assistance for full Windows support.