我想要将一些资源复制到2个不同的目录中。我怎样才能在POM中指定这个?Maven:我可以在WEB-INF和其他目录中复制资源吗?
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<version>2.6</version>
<executions>
<execution>
<id>copy-resources</id>
<!-- here the phase you need -->
<phase>validate</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<outputDirectory>
${project.build.directory}/${project.build.finalName}/lib
</outputDirectory>
<resources>
<resource>
<directory>${SOME_LIB}</directory>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
你的意思是说一个资源'a.txt'应该到'target/folderA/lib /'和另一个资源'b.png'到'target/folderB/lib /'?还是应该将两个/所有资源都分配到两个地方? – maba
所有资源到两个位置... target1/folderA/lib以及target2/folderB/lib – Aditya