1 2**NOTE**: This fork is currently being maintained for use in the promtail agent of the [Loki](https://github.com/grafana/loki) project. 3 4Use outside of that context is not tested or supported. 5 6# Go package for tail-ing files 7 8A Go package striving to emulate the features of the BSD `tail` program. 9 10```Go 11t, err := tail.TailFile("/var/log/nginx.log", tail.Config{Follow: true}) 12for line := range t.Lines { 13 fmt.Println(line.Text) 14} 15``` 16 17See [API documentation](http://godoc.org/github.com/hpcloud/tail). 18 19## Log rotation 20 21Tail comes with full support for truncation/move detection as it is 22designed to work with log rotation tools. 23 24## Installing 25 26 go get github.com/hpcloud/tail/... 27 28## Windows support 29 30This package [needs assistance](https://github.com/hpcloud/tail/labels/Windows) for full Windows support. 31