Hi,
We are working with Maven and Hudson for unit testing and war building. Copying sources (java and resources) to WEB-INF/src is required by our customer.
There is a simple way to do this with maven?
Thank you in advance.
Hi,
We are working with Maven and Hudson for unit testing and war building. Copying sources (java and resources) to WEB-INF/src is required by our customer.
There is a simple way to do this with maven?
Thank you in advance.
This should be possible by declaring the src/main/java
and src/main/resources
as additional Web Resource directories in the Maven War Plugin configuration. Inspired by the Adding and Filtering External Web Resources example:
...
<configuration>
<webResources>
<resource>
...
</resource>
<resource>
<directory>src/main/java</directory>
<!-- override the destination directory for this resource -->
<targetPath>WEB-INF/src</targetPath>
</resource>
<resource>
<directory>src/main/resources</directory>
<!-- override the destination directory for this resource -->
<targetPath>WEB-INF/src</targetPath>
</resource>
</webResources>
</configuration>
...