Clone this repo:
  1. 4b368d1 Merge pull request #56 from ActiveState/travis-gopkg-fix by Sridhar Ratnakumar · 2 years, 2 months ago master
  2. 8772f68 Test against latest Go versions in travis by Sridhar Ratnakumar · 2 years, 2 months ago
  3. 55f91c7 Workaround travis failures around gopkg.in imports by Sridhar Ratnakumar · 2 years, 2 months ago
  4. 0bf705a solicit help with Windows support by Sridhar Ratnakumar · 2 years, 2 months ago
  5. f3fe9b7 change log entry for last PR by Sridhar Ratnakumar · 2 years, 2 months ago

Build Status

Go package for tail-ing files

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.

Log rotation

Tail comes with full support for truncation/move detection as it is designed to work with log rotation tools.

Installing

go get github.com/ActiveState/tail/...

Windows support

This package needs assistance for full Windows support.