Create nice custom logs with options
package main
import (
log "github.com/igorpollo/go-custom-log
)
func main() {
log.Info("test")
log.Warning("test")
log.Error("test")
log.Success("test")
//Show only if debug mode is true or env var DEBUG=true
log.DebugMode(true)
log.Debug("test")
//Show time in messages
log.ShowTime(true)
}
Run go test -run ''
to see all logs outputs