You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
366 B

2 years ago
package main
import (
2 years ago
"git.echinacities.com/mogfee/protoc-gen-kit/example/service"
2 years ago
user "git.echinacities.com/mogfee/protoc-gen-kit/proto/v1"
2 years ago
"github.com/gin-gonic/gin"
)
func main() {
app := gin.Default()
srv := service.UserService{}
2 years ago
app.Use(func(c *gin.Context) {
c.Set("userId", 11)
})
2 years ago
user.RegisterUserHandler(app, &srv)
2 years ago
app.Run("localhost:8888")
}