For some weird reasons, I'm using local filetree based jars in the gradle classpath.
from sub-module(project), I want to exclude one of the local jar. but I'm missing the syntax for it, can someone provide me correct syntax to exclude the local jar file(s) as a transitive dependency here?
dependencies {
implementation(project(":my-simple-project")) {
exclude fileTree(dir: "../lib/", include: ["axis2-1.7.8/axis2-transport-http-1.7.8.jar"])
}
}
OR
dependencies {
implementation(project(":my-simple-project")) {
exclude files("../lib/axis2-1.7.8/axis2-transport-http-1.7.8.jar"])
}
}
I got an error as
* What went wrong:
A problem occurred evaluating project ':my-simple-project'.
> Could not find method exclude() for arguments [directory '../lib/'] on DefaultProjectDependency{dependencyProject='project ':my-simple-project'', configuration='default'} of type org.gradle.api.internal.artifacts.dependencies.DefaultProjectDependency.