在maven中配置
<!--插件配置-->
<build>
<resources>
<resource>
<directory>src/main/java</directory>
<!--包含了src/main/java目录下的所有xml资源配置文件-->
<includes>
<include>**/*.xml</include>
</includes>
</resource>
<resource>
<directory>src/main/resources</directory>
<includes>
<!--包含了src/main/resources目录下的所有资源配置文件,有别的格式的配置文件时,不要写成**/*.xml-->
<include>**/*</include>
</includes>
<filtering>false</filtering>
</resource>
</resources>
</build>
标签:xml,src,java,配置文件,导出,main
From: https://www.cnblogs.com/cony1/p/17428008.html