guillaume created MWAR-293: ------------------------------ Summary: NullPointerException if no directory specified in webResources tag Key: MWAR-293 URL: https://jira.codehaus.org/browse/MWAR-293 Project: Maven 2.x WAR Plugin Issue Type: Bug Affects Versions: 2.2 Environment: XP SP3, Eclipse Juno 4.2, Maven 3.0.4 Reporter: guillaume Priority: Critical
I would to exclude directories from the default web resources folder (src/main/webapp) and the documentation (http://maven.apache.org/plugins/maven-war-plugin/examples/adding-filtering-webresources.html) indicates that it can be done : Here's another example of how to specify include and exclude patterns: ... <configuration> <webResources> <resource> <!-- the default value is ** --> <includes> <include>**/pattern1</include> <include>*pattern2</include> </includes> <!-- there's no default value for this --> <excludes> <exclude>*pattern3/pattern3</exclude> <exclude>pattern4/pattern4</exclude> </excludes> </resource> </webResources> </configuration> ... But in this case, the plugin throws a NullPointerException : org.apache.maven.plugin.war.packaging.WarProjectPackagingTask (handleWebResources line 125). Indeed, the null reference of resource.getDirectory() given to File constructor leads to a null pointer... -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira