1
0
mirror of https://github.com/labstack/echo.git synced 2025-01-12 01:22:21 +02:00

Merge pull request #4 from mattn/windows

colorful logger on windows
This commit is contained in:
Vishal Rana 2015-03-30 20:59:20 -07:00
commit af69aac008

View File

@ -6,9 +6,11 @@ import (
"github.com/labstack/echo"
"github.com/labstack/gommon/color"
"github.com/mattn/go-colorable"
)
func Logger(h echo.HandlerFunc) echo.HandlerFunc {
log.SetOutput(colorable.NewColorableStdout())
return echo.HandlerFunc(func(c *echo.Context) {
start := time.Now()
h(c)