Skip to content

Commit 29b1ca4

Browse files
authored
Merge pull request #7 from tedbennett/verbose-logging
Move log behind verbose flag
2 parents 4955d67 + ff37d86 commit 29b1ca4

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

inotifywaitgo/watcher.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,10 @@ func WatchPath(s *Settings) {
5353
scanner := bufio.NewScanner(stdout)
5454
for scanner.Scan() {
5555
line := scanner.Text()
56-
log.Println(line)
56+
57+
if s.Verbose {
58+
log.Println(line)
59+
}
5760

5861
parts, err := parseLine(line)
5962
if err != nil || len(parts) < 2 {

0 commit comments

Comments
 (0)