Skip to content

Tipsy is command line interface helps you work with the gin framework

License

Notifications You must be signed in to change notification settings

YianAndCode/tipsy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tipsy

tipsy is command line interface helps you work with the gin framework

English | 简体中文

Introduction

Tipsy is a command-line tool written in Go for Gin framework projects. Similar to Laravel's artisan, it can initialize a new Gin project and quickly generate various components like entities, repositories, controllers, middlewares, and services.

Installation

go install github.com/YianAndCode/tipsy/cmd/tipsy@latest

Usage

Create a new project

To create a new Gin project:

tipsy create <project-name>

This command will generate a well-structured Gin project with the following directory layout:

.
├── cmd
│   └── api
│       └── bootstrap
└── internal
    ├── config
    ├── contract
    │   ├── constant
    │   │   └── errcode
    │   ├── datatype
    │   └── error
    ├── controller
    │   └── user
    ├── data
    ├── entity
    ├── log
    ├── middleware
    │   └── auth
    ├── repo
    │   └── user
    ├── router
    ├── server
    └── service
        └── user

Generate components

Tipsy provides several commands to generate different components:

  1. Create a new entity:
tipsy new entity <entity-name>
  1. Create a new repo:
tipsy new repo <repo-name>
  1. Create a new controller:
tipsy new controller <controller-name>
  1. Create a new middleware:
tipsy new middleware <middleware-name>
  1. Create a new service:
tipsy new service <service-name>

Each command will generate the corresponding Go source files with proper structure and basic implementations.

License

This project is licensed under the MIT License - see the LICENSE file for details.

About

Tipsy is command line interface helps you work with the gin framework

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages