```shell # https://gin-gonic.com/zh-cn/docs/quickstart/ go get -u github.com/gin-gonic/gin # https://github.com/swaggo/gin-swagger go install github.com/swaggo/swag/cmd/swag@latest swag init go get -u github.com/swaggo/gin-swagger go get -u github.com/swaggo/files ``` ```shell # [link](https://github.com/oapi-codegen/oapi-codegen/?tab=readme-ov-file) # this will then modify your `go.mod` go get -tool github.com/oapi-codegen/oapi-codegen/v2/cmd/oapi-codegen@latest #go:generate go tool oapi-codegen -config cfg.yaml ../../api.yaml go tool oapi-codegen -config cfg.yaml api.yaml ```