Skip to content
pavel edited this page Jul 6, 2021 · 2 revisions

You can setup the default textformatter to display fulltimestamps like so

package main

import (
	log "github.com/sirupsen/logrus"
)

func init() {
	log.SetFormatter(&log.TextFormatter{FullTimestamp: true})
}

func main() {
	log.Println("Fulltimestamp here")
}
Clone this wiki locally