Go language automatically generates projects and fixed code

written in front

Recently, I am finishing the design, the front desk is finished, and now I want to start building the back-end system, and most of the back-end systems are fixed templates.
So in order to facilitate fishing, by the way, write a code tool that can automatically generate templates

Open source address: https://github.com/CocaineCong/fgen

1. Project generation

1.1 Project structure

Currently only supports the generation of a single project structure directory, and will update the microservice distributed directory generation in the future

The effect is as follows
insert image description here

So first of all, the project directory structure I understand at this stage is the following structure:

demo/
├── api // 暴露出api接口,承接router转发的请求道service层
├── cmd // 项目启动
├── config // 配置文件存放
├── consts // 定义常量
├── loading // 加载配置
├── middleware // 

Guess you like

Origin blog.csdn.net/weixin_45304503/article/details/129458126