Gradle – Create Java project structure automatically

To quick start a new Gradle Java project, type gradle init –type java-library $ gradle init –type java-library :wrapper :init BUILD SUCCESSFUL Total time: 4.866 secs The following files and folders will be created automatically. P.S Tested with Gradle 2.0 1. Java Project Structure Both src/main/java and src/test/java folders are created. The Library*.java is a …

Read more

Ant – How to create a Java Project

In this tutorial, we will show you how to use Ant build tool to manage a Java project, compile, and package it into a Jar file. Technologies used : Eclipse 4.2 Ant 1.9.4 JDK 1.7 1. Create a Java Project In Eclipse IDE, create a new Java project named “AntDateUtils”. 2. Java Source Code Create …

Read more

Ant Template file to build a Java Project

Here’s a Apache Ant template file , best use to start a project from scratch. File : build.xml <project name="ProjectName" default="dist" basedir="."> <description> Project Description </description> <!– set global properties for this build –> <property name="projectName" value="ProjectName"/> <property name="src" location="src"/> <property name="build" location="build"/> <property name="dist" location="dist"/> <property name="webcontent" location="WebContent"/> <target name="init"> <!– Create the time …

Read more