备注:我使用的是 idea
方式一:在pom.xml中添加 spring boot maven打包插件
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<skipTests>true</skipTests>
</plugin>
</plugins>
</build>
方式二: pom.xml 中的 properties 设置
<properties>
<skipTests>true</skipTests>
</properties>

本文介绍了在SpringBoot项目中使用Maven进行打包的两种有效方式。第一种是在pom.xml中添加spring-boot-maven-plugin插件,并设置skipTests属性为true以跳过测试。第二种方式是在properties中直接设置skipTests属性,同样达到跳过测试的目的,从而提高打包效率。
2830

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



