can you please describe option in gradle 1.9 to de-dup the zip files created by war plugin ? Have seen netmikey’s solution here: http://forums.gradle.org/gradle/topics/solution_for_copying_a_subdirectory_wihtin_a_zip_into_another_zip but no joy on solving my dup-zip entry problem
Either make sure that you don’t add duplicate entries, or use ‘war.duplicatesStrategy = “EXCLUDE”’, in which case the first resource added will win.
can confirm this solution works in our caelyf deployments. thx
And for pathing jar?
task pathingJar(type: Jar) {
appendix = “pathing”
doFirst {
manifest {
this.ext.suppath = new ArrayList();
configurations.compile.files { println "compileFile: " + it.name }
configurations.compile.files { this.ext.suppath.add("/usr/sup/jars/" + it.name + “-” + it.version + “.jar”)}
for (String s : this.ext.suppath) { print s + " "}
println “\n … and the pipe jar is”
for (String s : this.ext.pipejar) { print s + “!\n”}
attributes “Class-Path”: (this.ext.suppath.join(" “) + " " + project.ext.pipejar.join(” "))
}
} } and it appears the compile config has the dupes as seen below
:pathingJar compileFile: jpsgcs-core compileFile: logback-core compileFile: logback-classic compileFile: logback-access compileFile: slf4j-api compileFile: jopt-simple compileFile: jpsgcs-core compileFile: logback-core compileFile: logback-classic compileFile: logback-access compileFile: slf4j-api compileFile: jopt-simple