Code Refactoring and modifications
This commit is contained in:
parent
eaac82ceb9
commit
370a490643
9 changed files with 75 additions and 91 deletions
|
@ -20,6 +20,7 @@ func (logD *logDirectory) createLogDir(prefix string, startTime time.Time) {
|
|||
|
||||
if logD.name == "" {
|
||||
// Creating directory to store all logs for this run
|
||||
// directory name format - 2019-November-21_14-33-0
|
||||
logDirName := strings.Join([]string{"./", prefix, strconv.Itoa(startTime.Year())}, "")
|
||||
logDirName = strings.Join([]string{logDirName, startTime.Month().String(), strconv.Itoa(startTime.Day())}, "-")
|
||||
logDirName = strings.Join([]string{logDirName, strconv.Itoa(startTime.Hour())}, "_")
|
||||
|
|
Reference in a new issue