Hi, my current configuration of the maven-jar-plugin in my base-pom automatically generates a -tests.jar file in the target folder (that is exactly what i want, for most of my projects).
<plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId> <version>${jar.plugin.version}</version> <executions> <execution> <goals> <goal>test-jar</goal> </goals> </execution> </executions> </plugin> It is also deployed to the remote repository as desired. All my projects are derived from this parent-pom. The only problem is, that with this config the -tests.jar will ALWAYS be generated, even if there are no test sources available. (It just contains the META-INF folder with the MANIFEST.MF plus the pom.xml and the pom.properties.) Can i configure it anyhow, to automatically detect that the project has a <packaging>pom</packaging> and thus has no tests at all, or to take a look into the test/sources/ folder and find out it is not available or the folder is empty? In fact, i would like to skip the generation of the -tests.jar for those general projects: - maven-base (our base project) - maven-archetype (our companies general archetype) - maven-site-skin (our company site skin) and as well for multi-module parents - sandbox (itself is a pom, with some sub-modules) The only thing that comes to my mind right now, is that i could define a property (in every project/module) that would for e.g. set the goal <jar.plugin.goal>none</jar.plugin.goal> or <jar.plugin.goal>test-jar</jar.plugin.goal>. But then i need to set this property in every module of all my projects. I just wonder if there is any better solution, with some automated way. Thanks for help in advance! br R.C. -- View this message in context: http://maven.40175.n5.nabble.com/omitting-tests-jar-for-pom-modules-tp4935461p4935461.html Sent from the Maven - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org