[GRADLE-1092] Eclipse classpath generation ignores excludes in 0.9-rc1 Created: 05/Aug/10  Updated: 04/Jan/13  Resolved: 19/Apr/11

Status: Resolved
Project: Gradle
Affects Version/s: 0.9
Fix Version/s: 1.0-milestone-3

Type: Bug
Reporter: Bryan Keller Assignee: Peter Niederwieser
Resolution: Fixed Votes: 6


 Description   

The "eclipseClasspath" task seems to ignore configuration excludes when generating the Eclipse .classpath file. The resulting .classpath file includes all transitive dependencies, even ones that have been excluded by configuration.

Here is an example script that demonstrates the issue:

apply plugin: "java"
apply plugin: "eclipse"

repositories {
mavenCentral()
}

configurations {
compile

{ exclude group:"commons-logging" }

}

dependencies {
compile "org.springframework:spring-core:3.0.3.RELEASE"
}

When you run "gradle eclipseCp" with 0.9preview3, commons-logging is not added to the .classpath file, as expected. When you run "gradle eclipseClasspath" with 0.9rc1, commons-logging IS added to the .classpath file.



 Comments   
Comment by Ben Dotte [ 13/Oct/10 ]

This is also a problem when generating idea projects. As a workaround, I have been excluding transitives on the dependencies depending on the unwanted jars.

Generated at Wed Jun 30 11:46:42 CDT 2021 using Jira 8.4.2#804003-sha1:d21414fc212e3af190e92c2d2ac41299b89402cf.