Skip to content

Latest commit

 

History

History
30 lines (19 loc) · 603 Bytes

README.md

File metadata and controls

30 lines (19 loc) · 603 Bytes

golog

Severity-based key/value logging replacement for Go's standard logger.

Outputs a message, along with a set key/value pairs for easy parsing.

Example:

// import "github.com/timehop/golog/log"

log.Error("MyLibrary", "Could not connect to server.", "url", url, "error", err.Error())
log.Info("MyLibrary", "Something happened.")

Would output something like:

ERROR | MyLibrary | Could not connect to server. | url='http://timehop.com/' error='timed out'
INFO  | MyLibrary | Something happened.

Build

License

MIT