buildship
buildship copied to clipboard
how to add compileOnly module dependencies in to eclipse build path libary
my eclipse is STS 4.12.1.RELEASE and gradle is v7.3. the build ship version is 3.1.5.
there are two module in my project , moduelA,moduleB. the moduleB depends on moduleA with compileOnly.
dependencies {
compileOnly(project(":moduleA"))
testImplementation("org.junit.jupiter:junit-jupiter-api")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")
}
how to add modulA into moduleB build path libary?
i do not want to change compileOnly to Implementation. this project work good with gradlew build. and work ok in idea.
but it can not work in eclipse.
I'm try to resolve like this
plugins {
`java-library`
`maven-publish`
`eclipse`
id("io.spring.dependency-management")
}
eclipse {
classpath {
plusConfigurations.plus(configurations.compileOnly)
}
}
but it can not work.
the projec is here
https://github.com/ldwqh0/buildship-problem.git
helpme
Me too
for me it worked like this:
configurations {
eclipseExtraClasspath.extendsFrom compileOnly
}
eclipse.classpath {
plusConfigurations += [ configurations.eclipseExtraClasspath ]
}
Hi anyone, I tried this latest fix and it seems to me it results in "Unresolved dependencies" when using compileOnly together with version catalogues because the version is not resolved. Can anyone confirm?