I have the following simple build.gradle file:
apply plugin: 'application'
apply plugin: 'java'
mainClassName = 'com.kurtis.HelloGradle'
And the following single Java file located at src/main/java/com/kurtis/HelloGradle.java:
package com.kurtis;
public class HelloGradle {
public static void main(String[] args) {
System.out.println("Hello gradle");
}
}
However, if I run gradle build, I get jar in a directory build/libthat does not have a core set of classes. The manifest file has no entry Main-Class. Why is this?
source
share