Generate Project
The cleanArchitecture | ca
task will generate a clean architecture structure in your project.
Caution: If you run this task on an existing project it will override the main.gradle
, build.gradle
and gradle.properties
files.
Parameter | Description | Usage | Default Value |
---|---|---|---|
package | You can specify the main or default package of your project | --package=<desired.base.package> | co.com.bancolombia |
type | Define if project shoud be created around reactive or imperative aproach | --type=<imperative or reactive> | reactive |
name | Sets projects name | --name=<Project name> | cleanArchitecture |
lombok | Specify if you want to use this plugin | --lombok=<true or false> | true |
metrics | Specify if you want to enable this feature with micrometer | --metrics=<true or false> | true |
mutation | Specify if you want to enable mutation testing framework on this project | --mutation=<true or false> | true |
javaVersion | Sets Java version | --javaVersion= <VERSION_17 or VERSION_21> | VERSION_17 |
Examples:
gradle cleanArchitecture --package=co.com.bancolombia --type=reactive --name=NameProject --lombok=true
gradle ca --package=co.com.bancolombia --type=reactive --name=NameProject --lombok=true
The generated structure will look like this for java:
π¦NameProject
β£ πapplications
β β πapp-service
β β β£ πsrc
β β β β£ πmain
β β β β β£ πjava
β β β β β β π[package]
β β β β β β β£ πconfig
β β β β β β β β π[configs and beans]
β β β β β β β πMainApplication.java
β β β β β πresources
β β β β β β£ π[properties]
β β β β πtest
β β β β β πjava
β β β β β β π[package]
β β β πbuild.gradle
β£ πdeployment
β β£ π[Dockerfile, Pipelines as a code]
β£ πdomain
β β£ πmodel
β β β£ πsrc
β β β β£ πmain
β β β β β πjava
β β β β β β π[package]
β β β β πtest
β β β β β πjava
β β β β β β π[package]
β β β πbuild.gradle
β β πusecase
β β β£ πsrc
β β β β£ πmain
β β β β β πjava
β β β β β β π[package]
β β β β πtest
β β β β β πjava
β β β β β β π[package]
β β β β β β β πusecase
β β β πbuild.gradle
β£ πinfrastructure
β β£ πdriven-adapters
β β£ πentry-points
β β πhelpers
β£ π.gitignore
β£ πbuild.gradle
β£ πgradle.properties
β£ πlombok.config
β£ πmain.gradle
β£ πREADME.md
β πsettings.gradle