If maven and eclipse build outputs disagree, you likely won't be able to run tests or launch application from eclipse. Either change eclipse to use maven convention (the default in m2e) or configure pom.xml build <outputDirectory> and <testOutputDirectory> to match what you use in eclipse.
m2e runs significant part of maven build inside eclipse workspace. When eclipse and maven output directories disagree, some of the generated files, e.g. .class files produced by eclipse java builder, will end up in eclipse output directory and others, e.g. resources processed by maven-resources-plugin, in maven output directory. Run-as java application or junit test only knows how to use eclipse output directory and will miss any resources or classes generated into maven output directory. -- Regards, Igor On 2015-03-05 23:05, V. Mark Lehky wrote:
Hello. I have an existing Eclipse project that I have been tasked with Maven-izing. The current project was using the Eclipse default "build/classes" for it's output folder. When I added the m2e nature, the output folder was changed to the Maven default "target/classes". From previous experience, if I run both an Eclipse build and a Maven build (using the same output folder), then things can get confused, and I have to use some Maven-clean, Eclipse-clean, build trickery to get out of it. My question is: Is it a good/bad idea to force the Eclipse build output folder to be "build/classes", and leave the Maven build output folder to "target/classes", thereby hopefully never having the two meet and confuse each other? What could go wrong with this scenario? Thank You, VML. _______________________________________________ m2e-users mailing list [email protected] To change your delivery options, retrieve your password, or unsubscribe from this list, visit https://dev.eclipse.org/mailman/listinfo/m2e-users
_______________________________________________ m2e-users mailing list [email protected] To change your delivery options, retrieve your password, or unsubscribe from this list, visit https://dev.eclipse.org/mailman/listinfo/m2e-users
