Categorygithub.com/Findryankp/cleanarchGo
repositorypackage
1.1.2
Repository: https://github.com/findryankp/cleanarchgo.git
Documentation: pkg.go.dev

# Packages

No description provided by the author

# README

cleanarchGo

💫 About

Clean architecture starter pack for faster and easier feature creation using Go.

  • This pack includes Clean Architecture with the Echo framework, Gorm, Viper (env), Govalidator, Jwt, and more.
  • You can create CRUD features in less than one minute
  • .gitignore , Dockerfile will also be generated too.
  • Auth feature and users feature will also generated :
🔗 Auth Routes
MethodEndpointParamsJWT TokenFunction
POST/login-NOLogin User
POST/register-NORegister User
POST/change-password-YESChange Password
GET/claim-token-YESGet Token Data
🔗 Users Routes
MethodEndpointParamsJWT TokenFunction
GET/users-NOGet All Users
GET/usersidNOGet User By Id
PUT/usersidNOEdit User
DELETE/usersidNODelete user

🚀 Import

go get -u github.com/Findryankp/cleanarchGo@latest

👨🏽‍💻 Step By Step

  1. First step, add this syntax to your main function in file main.go
cleanarchGo.Init();
  • for example :
  1. Run this syntax in cmd/ terminal
go run . init
  • If success, the files that will be generated are :
  • configs database
  • middlewares (jwt auth, logs, cors)
  • environment (local.env)
  • etc
  1. Set local.env with your own configuration database

🚀 Create new feature

  • run this syntax in your cmd/terminal
go run . features featuresNames
  • ex : go run . features rooms

  • CRUD Features, Code all layer, route, and migratiton feature from your featureNames will be created

🔗 featureNames Routes
MethodEndpointParamsJWT TokenFunction
POST/featureNames-NOPost a featureNames as a host
GET/featureNames-NOGet All Available your featureNames
GET/featureNamesidNOGet featureNames Detail
PUT/featureNamesidNOEdit featureNames
DELETE/featureNamesidNODelete featureNames

🎯 Run Project

go run .
  • try with your postman or another

😎 Development by

Findryankp findryankp