我在Spring Boot项目上工作,并且在有效的pom.xml中有此配置:
<resources>
<resource>
<filtering>true</filtering>
<directory>/home/farid/Travaux/ng-with-boot/src/main/resources</directory>
<includes>
<include>**/application*.yml</include>
<include>**/application*.yaml</include>
<include>**/application*.properties</include>
</includes>
</resource>
<resource>
<directory>/home/farid/Travaux/ng-with-boot/src/main/resources</directory>
<excludes>
<exclude>**/application*.yml</exclude>
<exclude>**/application*.yaml</exclude>
<exclude>**/application*.properties</exclude>
</excludes>
</resource>
</resources>
我只想添加另一个conf将前端应用程序复制到静态文件夹,所以我这样做了:
<resources>
<resource>
<directory>src/main/frontend/dist</directory>
<targetPath>static</targetPath>
</resource>
</resources>
但是,现在,以前的配置没有保留。
如何在不删除Spring Boot配置的情况下复制新文件?