I have a Java project using m2eclipse. In my Eclipse, I get several Warnings.
How can I display those warnings in my maven compilation? I want to use warnings-plugin on jenkins to keep track of the number of warnings.
I found this post on how to enable warnings in maven, but it only gives me a small subset of warnings.
E.g.
“The value of … is not used” warnings don’t show up.
How can I get the same warnings as displayed in Eclipse?
Thanks for help 🙂
Edit for clarity: I would like to display the same warnings as in eclipse, not other bugs as reported by FindBugs, PMD or checkstyle
I finally found a solution for my problem, so I wanna share it 🙂
I added this to my pom-file, and now the warnings show up during compilation with maven, and I was able to include them to jenkins using the warnings plugin.
The important thing I missed in my first attempts was, that the plugins need to be under pluginManagement.
The warnings are generated by a specific compiler, to prevent the error “no such compiler: eclipse” the dependency to the plexus-compiler is included.
Hope this works for others as well 🙂