[ http://jira.codehaus.org/browse/MJAR-101?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=131685#action_131685 ]
cunparis edited comment on MJAR-101 at 4/22/08 4:49 AM: -------------------------------------------------------------- Can you post more of your pom.xml? For me the properties go in the jar but not in the jar of the test classes. <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId> <executions> <execution> <goals> <goal>jar</goal> </goals> <configuration> <excludes> <exclude>**/*.properties</exclude> </excludes> </configuration> </execution> </executions> </plugin> </plugins> </build> was (Author: cunparis): (report updated) > excluding files from jar doesn't work completely well > ----------------------------------------------------- > > Key: MJAR-101 > URL: http://jira.codehaus.org/browse/MJAR-101 > Project: Maven 2.x Jar Plugin > Issue Type: Bug > Affects Versions: 2.2 > Environment: Windows XP, JDK 1.5 > Reporter: Patrizio Munzi > Attachments: mavenjarplugin.bug.tar.gz > > > Maven Jar Plugin exclude feature seems not to work completely well. > It actually excludes the specified files from the built jar but creates > however the folders path into it. > Here's my configuration: > {code:xml} > <excludes> > <exclude>**/*.properties</exclude> > <exclude>**/*.xml</exclude> > <exclude>**/*.xsd</exclude> > </excludes> > {code} > Although all the specified files are actually excluded from the deployed > jar, the directory paths of the excluded files are still created into > the jar. > I mean, if I have the following files under the resources directory: > resources/log4j.properties > resources/xml/file.xml > resources/xml/schema/schema.xsd > These files won't be included in the built jar, but I'll still have the > following path into it: > /xml/schema/ > Find attached a simple project test case to reproduce the problem. > - Extract it > - Change to the main dir > - run: mvn compile > - run: mvn jar:jar -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira