Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for _, tailFile := range files {
- t, _ := tail.TailFile(tailFile, c)
- // Goroutine per tailing file
- go func() {
- for line := range t.Lines { // t.Lines is a channel
- // Do some magic here
- }
- }()
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement