Documentation
Available Commands
Reference for every goclean command and flag.
goclean new
Creates a new project. Run it without options for the interactive stack wizard, or pass flags.
syntax
goclean new [project-name] [flags]examples
goclean new my-saas --router chi --database postgres
goclean new my-app --database sqlite --module github.com/me/my-app--router—gin(default) orchi.--database—postgres(default),mysqlorsqlite.--orm—gorm(default).-m, --module— Go module path, e.g.github.com/username/project.-d, --db— PostgreSQL database name (default<project>_db).--no-git— skipgit init.--no-tidy— skipgo mod tidy.
goclean make:module
Generates a whole module: entity, repository, usecase, handler and migration. Also available as make:resource.
syntax
goclean make:module <Name> [field:type ...] [flags]example
goclean make:module Product name:string price:float stock:int active:boolField types: string, text, int, int64, float, bool, time, uuid. The type defaults to string. Use --no-register to skip patching container.go and routes.go.
Single-piece generators
make:entity— a domain entity.make:types— request, input and response DTO types.make:repo— repository interface and GORM implementation.make:usecase— usecase interface and implementation.make:handler— an HTTP Gin handler.make:migration— up and down migration files.
Other commands
doctor— check that Go, git and Docker are installed and recent enough.version— print the goclean version.completion— generate a shell autocompletion script.
Global flags
--dry-run— show what would be generated without writing anything.--force— overwrite existing files.
preview first
goclean make:module Product name:string price:float --dry-run