Merge branch 'tcheneau-typo-fix'
tree: 6b481e235b794bc2fa20f4c3e70e3697d50d964f
  1. cmd/
  2. Godeps/
  3. ratelimiter/
  4. util/
  5. watch/
  6. winfile/
  7. .gitignore
  8. .travis.yml
  9. CHANGES.md
  10. Dockerfile
  11. LICENSE.txt
  12. Makefile
  13. README.md
  14. tail.go
  15. tail_posix.go
  16. tail_test.go
  17. tail_windows.go
README.md

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/hpcloud/tail/...

Windows support

This package needs assistance for full Windows support.