Maven配置资源过滤excludes没有作用???搞了很久没能明白???,求解
这是我的项目结构
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId></artifactId>
<packaging>war</packaging>
<version>0.0.1-SNAPSHOT</version>
<name></name>
<url>http://maven.apache.org</url>
<properties>
<spring.version>4.0.5.RELEASE</spring.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
</dependencies>
<build>
<finalName>${project.artifactId}</finalName>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
<encoding>${project.build.sourceEncoding}</encoding>
<skip>true</skip>
</configuration>
</plugin>
</plugins>
<filters>
</filters>
<resources>
<resource>
<directory>${basedir}/src/main/resources</directory>
<filtering>true</filtering>
<excludes>
<exclude>generatorConfig.xml</exclude>
</excludes>
</resource>
</resources>
</build>
</project>
我想在打包的时候把srcmainresoursgeneratorConfig.xml的这个文件过滤掉,但是配置没有用?求解???
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Maven Resources Plugin
The mapping matches URLs using the following rules:
*
matches zero or more characters (匹配0个或N个字符)**
matches zero or more directories in a path (匹配0个或N个目录)Examples
com/*.jsp
— matches all.jsp
files in the com directorycom/**/test.jsp
— matches alltest.jsp
files underneath the com path楼主可以将表达式写成如下尝试: