prometheus-adapter/vendor/github.com/hpcloud/tail
Solly Ross cc08a1fb41 Switch to ginkgo/gomega for tests
This switches over to ginkgo/gomega for tests, which makes writing
certain tests easier/more fluent in the future.
2018-10-03 11:05:43 -04:00
..
ratelimiter Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
util Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
watch Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
winfile Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
.gitignore Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
.travis.yml Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
appveyor.yml Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
CHANGES.md Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
Dockerfile Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
LICENSE.txt Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
Makefile Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
README.md Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
tail.go Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
tail_posix.go Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00
tail_windows.go Switch to ginkgo/gomega for tests 2018-10-03 11:05:43 -04:00

Build Status 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.