文章目录
Maven解决资源无法导出
Maven由于他的约定大于配置,我们之后可能遇到我们写的配置文件,无法导出或者无法生效的问题,解决方案
<!--在pom.xml的build中配置resources,来防止我们资源导出失败的问题-->
<build>
<resources>
<resource>
<directory>src/main/resources</directory>
<includes>
<include>**/*.properties</include>
<include>**/*.xm1</include>
</includes>
<filtering>true</filtering>
</resource>
<resource>
<directory>src/main/java</directory>
<includes>
<include>**/*.properties</include>
<include>**/*.xml</include>
</includes>
<filtering>true</filtering>
</resource>
</resources>
</build>
```