Skip to main content
Develop. Fast. First.
Go Gin Boilerplate
A development boilerplate based on the Gin framework, aimed at helping developers quickly build and develop web applications.
Get Started
GitHub
Quick Start
Installations
go install github.com/sanjayheaven/ggb@latest
Init a new project
ggb init ggb
cd ggb
go mod download
Config Setup
cp configs/config.example.yaml configs/config.yaml
Run Project
go run main.go server
Why use this boilerplate?
Fast Development
Using the Gin framework and related tools to speed up the development and iteration process of the project.
Easy to use
Follow the project-layout specification and provide a clear and simple code structure so that novices can easily get started.
Advanced CLI
Using Cobra to build modern command line tools to simplify project management and operations.
Hot reload
Using Air tool, support hot reload, improve development efficiency.
Logging system
Integrated Logrus, Zap and Lumberjack to achieve all-round log recording and management.
Database support
Integrated Gorm, support mainstream databases such as MySQL, PostgreSQL, etc.
Flexible middleware
Integrate common middleware to easily implement functions such as logging, authentication, cross-domain, and flow control.
API document
Use Gin-Swagger to generate API documents for easy viewing and debugging of interfaces.
Develop. Fast. First.