I’m tearing my hair out trying to get the eclipse integration to accept a class output directory separate from “bin/main” in my Java proect, but it completely ignores whatever I tell it. I’ve tried changing the source sets in any way I can think of. I’ve played with the defaultOutputDir of the eclipse task, but it is simply refusing to generate a .classpath with anything except the default dir. And “bin” is used for something else in our project, so it is not possible to use that one…
Why is it flat-out ignoring “outputdir” from below when generating the .classpath for eclipse?
outputDir = file(‘foobar’)
Similarly, if I add the following, it still sets up “bin/main”
defaultOutputDir = file(‘foobar’)
I’ve read the API documentation back and forth on the eclipse tasks as well as the SourceSet-related classes, and I don’t see any way to do this. Isn’t it possible to generate a .classpath with anything except the bin/-prefix?
Note: using gradle-5.0.
Edit: I seem to be able to overwrite the “bin” paths with the code supplied in the answer on this post: https://stackoverflow.com/questions/17451567/splitting-main-and-test-in-gradles-eclipse-builds
But is that really the only way to change the output directories? It seems quite complicated for such an easy thing.