在 pom 文件的 build 标签加上 spring-boot-maven-plugin 插件即可。
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>=
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>repackage</goal>
</goals>
</execution>
</executions>
<configuration>
<includeSystemScope>true</includeSystemScope>
<mainClass>com.xxx.xxx.xxx</mainClass>
</configuration>
</plugin>
本文介绍了如何在Maven的pom文件中配置spring-boot-maven-plugin插件,通过添加<plugin>标签,设置<groupId>、<artifactId>、<executions>和<configuration>等属性,实现对Spring Boot应用的打包操作,包括指定打包后的主类。
3549

被折叠的 条评论
为什么被折叠?



