This templates helps you to create portable Java projects.
We recommend you to use Ubuntu to the correctly use of this templates.
In order to generate a Java project this template you need to install the following softwares:
- SDKMAN - Software Development Kit Manager
Open your terminal and type the command below:
sdk install java
sdk install maven
sdk install gradle
sdk install lazybones
Lazybones allows you to create a new project structure for any framework or library for which the tool has a template.
If you want more information about lazybones project check it out here and here
Open the terminal and execute the commands below:
mkdir -p $HOME/Projects/Java
Open the terminal and execute the commands below:
cd $HOME/Projects/Java
git clone https://github.com/CIDAC/java-templates.git
Open the terminal and execute the commands below:
cd $HOME/Projects/Java/java-templates
./gradlew installAllTemplates
To see if the templates were installed:
lazybones list --cache
If you want to use Microsoft Visual Studio Code (VS Code) follow the instructions bellow to configure the Editor.
Create a file called settings.json and add the following properties:
{
"explorer.confirmDelete": false,
"editor.tabSize": 2,
"editor.tabCompletion": true,
"files.autoSave": "afterDelay",
"files.autoSaveDelay": 5000,
"editor.renderWhitespace": "all"
}
You could also use the following plugins:
- Debugger for Java
- Java Extension Pack
- Language Support for Java(TM) by Red Hat
- Git Project Manager
- gitLens - Git supercharged
- Docker
- markdownlint
Our template will generate a Spring boot Java project configured with:
- Gradle
- Spring Boot
- Spring Data JPA
- Logback
- Docker
- FlywayDB
- PostgreSQL connection database
- Guava
- Spring Actuator
- Swagger
To create a spring-boot-web project follow the instructions of this link.