Move internal output to INFO level Prevent client applications from having to deal with text being forced to their stdout by using INFO rather than fmt for output.
diff --git a/README.md b/README.md index f2447dc..c6f327c 100644 --- a/README.md +++ b/README.md
@@ -115,6 +115,9 @@ } ``` +Note that JWW's own internal output uses log levels as well, so set the log +level before making any other calls if you want to see what it's up to. + ### Using a temp log file JWW conveniently creates a temporary file and sets the log Handle to
diff --git a/thatswhyyoualwaysleaveanote.go b/thatswhyyoualwaysleaveanote.go index 2f3d721..c7bbec9 100644 --- a/thatswhyyoualwaysleaveanote.go +++ b/thatswhyyoualwaysleaveanote.go
@@ -141,7 +141,8 @@ CRITICAL.Println("Failed to open log file:", path, err) os.Exit(-1) } - fmt.Println("Logging to", file.Name()) + + INFO.Println("Logging to", file.Name()) LogHandle = file initialize() @@ -154,7 +155,7 @@ CRITICAL.Println(err) } - fmt.Println("Logging to", file.Name()) + INFO.Println("Logging to", file.Name()) LogHandle = file initialize()