Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mukezhz/geng
Generate Golang Project CLI
https://github.com/mukezhz/geng
cli generator gin go golang golang-generator project
Last synced: about 1 month ago
JSON representation
Generate Golang Project CLI
- Host: GitHub
- URL: https://github.com/mukezhz/geng
- Owner: mukezhz
- License: mit
- Created: 2023-11-14T12:20:10.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-07-19T06:29:13.000Z (6 months ago)
- Last Synced: 2024-12-06T02:12:46.955Z (about 2 months ago)
- Topics: cli, generator, gin, go, golang, golang-generator, project
- Language: Go
- Homepage: https://mukezhz.github.io/geng
- Size: 430 KB
- Stars: 52
- Watchers: 4
- Forks: 4
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Roadmap: docs/roadmap.md
Awesome Lists containing this project
README
# geng Documentation [WIP]
Fullform: `Gen`erate `G`olang Project
## Introduction
- Inspired by Nest CLI `geng` is command-line interface tool that helps you to initialize, develop, and maintain your Go gin applications
- By default it will generate the clean code architecture of [wesionaryTEAM](https://github.com/wesionaryTEAM/go_clean_architecture)## Installation
- Pre-requisite: You need to install the golang in your system: [golang installation](https://go.dev/doc/install)
```zsh
go install github.com/mukezhz/geng@latest
```**Alternative Install**
- Download and execute binary by downloading from [assets](https://github.com/mukezhz/geng/releases)**Add binary dir to your PATH variable [If geng command didn't work after installation]**
```zsh
// For zsh: [Open.zshrc] & For bash: [Open .bashrc]
// Add the following:
export GO_HOME="$HOME/go"
export PATH="$PATH:$GO_HOME/bin"// For fish: [Open config.fish]
// Add the following:
fish_add_path -aP $HOME/go/bin
```## Basic workflow
- Get help
```zsh
geng help
```
- Create a new project
```zsh
geng new -m [-d ]
```
- Use Interactive to create new project
```zsh
geng new
```
- Start project
```zsh
cd
cp .env.example .env
go mod tidygo run main.go
```
- Generate module in already existing project
```zsh
// Project needs to initialize git repository to work module generation
geng gen module
```**NOTE:** default supported version is of `golang 1.20`
### TODO LIST:
- [x] generate a new project
- [x] get project module, project name and directory as command line argument
- [x] generate a module
- [x] refactor the code -> make code clean
- [x] modify the parent features `module.go` when new module is added
- [x] implement CI for assets build
- [x] add option to generate constructor of aws, gcp while project generation
- [ ] allow different template options when building project
- [ ] generate test case template
- [ ] generate hexagonal architecture
- [ ] generate route, controller and dtos from bru file### Diagrams
### Logo
**Thank You!!!**