filename generates the name of the logfile from the current time.
()
| 290 | |
| 291 | // filename generates the name of the logfile from the current time. |
| 292 | func (l *Logger) filename() string { |
| 293 | if l.Filename != "" { |
| 294 | return l.Filename |
| 295 | } |
| 296 | name := filepath.Base(os.Args[0]) + "-lumberjack.log" |
| 297 | return filepath.Join(os.TempDir(), name) |
| 298 | } |
| 299 | |
| 300 | // millRunOnce performs compression and removal of stale log files. |
| 301 | // Log files are compressed if enabled via configuration and old log |
no outgoing calls
no test coverage detected