在pom.xml中加入
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<classifier>execute</classifier>
<mainClass>com.chuangqi.ResourceManagementApplication</mainClass>
</configuration>
<version>1.3.7.RELEASE</version>
<executions>
<execution>
<goals>
<goal>repackage</goal><!--可以把依赖的包都打包到生成的Jar包中-->
</goals>
</execution>
</executions>
</plugin>
</plugins>
<resources>
<resource>
<directory>src/main/resources</directory>
<includes>
<include>*.*</include>
<include>static/**</include>
<include>templates/**</include>
</includes>
</resource>
<resource>
<directory>src/main/java</directory>
<includes>
<include>**/*.xml</include>
</includes>
<filtering>true</filtering>
</resource>
</resources>
</build>
然后maven执行clean 在install
标签:xml,src,1.3,boot,idea,maven,完整包,main From: https://blog.51cto.com/u_15973676/6069211