hey all,
I want to compile a java project with gradle, i tried with the script but the problem is that i have jars that are defined in the file .classpath and in the lib repertory but it’s not reading the jars.
apply plugin: 'java'
apply plugin:'application'
sourceCompatibility = 1.8
targetCompatibility = 1.8
sourceSets {
main {
java {
srcDir 'src'
}
}
}
repositories {
mavenCentral()
}
dependencies {
compile 'org.slf4j:slf4j-api:1.7.12'
testCompile 'junit:junit:4.12'
}
Then I executed the script with this command : gradle build
The project structure:
file .classpath :
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="lib" path="/app/ATG/ATG11.2/DCS/lib/resources.jar"/>
<classpathentry kind="lib" path="/app/ATG/ATG11.2/DCS/lib/classes.jar"/>
........
<classpathentry kind="output" path="classes"/>
</classpath>
Regards.