Skip to content

easonlin404/gin-zerolog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Gin-Zerolog

Gin middleware for Logging with zerolog.

Travis branch Codecov branch Go Report Card GoDoc

Usage

Start using it

Download and install it:

$ go get github.com/easonlin404/gin-zerolog

Import it in your code:

import "github.com/easonlin404/gin-zerolog"

Canonical example:

package main

import (
	"github.com/easonlin404/gin-zerolog"
	"github.com/gin-gonic/gin"
)

func main() {

    r := gin.Default()
    r.Use(ginzerolog.Logger())

    r.GET("/", func(c *gin.Context) {
    	// your code
    })

    r.Run()
}

About

Gin middleware for Logging with zerolog

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages