Go package for reading from continously updated files (tail -f)
Go
2,780
72 commits
updated Oct 25, 2022
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.
Overall
Maintained
Code review
Go module
Latest release
Releases this year
(top 24 of 27)
1,427 followers · starred Jun 2015
308 followers · starred Oct 2017
508 followers · starred May 2016
1,000 followers · starred Nov 2013
Go package for reading from continously updated files (tail -f)
Go
2,780
72 commits
updated Oct 25, 2022
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.
Overall
Maintained
Code review
Go module
Latest release
Releases this year
(top 24 of 27)
1,427 followers · starred Jun 2015
308 followers · starred Oct 2017
508 followers · starred May 2016
1,000 followers · starred Nov 2013