Skip to content

Logs time and message on the same line.

License

Notifications You must be signed in to change notification settings

iamdanielyin/logrusfmt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

logrusfmt

Logs time and message on the same line.

Example:

package main

import (
	log "github.com/sirupsen/logrus"
	fmt "github.com/yinfxs/logrusfmt"
)

func main() {
	log.SetFormatter(&fmt.SimpleTextFormatter{})
	log.WithFields(log.Fields{
		"animal": "walrus",
	}).Info("A walrus appears")
}

About

Logs time and message on the same line.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages