Skip to content

A simple example of a Java jar library built using Gradle

License

Notifications You must be signed in to change notification settings

dmhendricks/hn.daniel.HelloWorld

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Author License DigitalOcean Twitter

hn.daniel.HelloWorld

A simple example of a jar library built using Gradle.

Requirements

Building

The following commands will create: build/libs/helloworld-0.1.0.jar

gradle clean
gradle buildJar

Example Usage

Copy the generated jar file to your project's lib directory.

import hn.daniel.HelloWorld;
...
String helloWorld = HelloWorld.hello();
System.out.println(helloWorld);
String helloDaniel = HelloWorld.hello("Daniel");
System.out.println(helloDaniel);

Output

Hello world!
Hello Daniel!

Analytics