mvn clean package依次执行了clean、resources、compile、testResources、testCompile、test、jar(打包)等7个阶段。


mvn clean install依次执行了clean、resources、compile、testResources、testCompile、test、jar(打包)、install等8个阶段。


mvn clean deploy依次执行了clean、resources、compile、testResources、testCompile、test、jar(打包)、install、deploy等9个阶段。

 

由上面的分析可知主要区别如下,

package命令完成了项目编译、单元测试、打包功能,但没有把打好的可执行jar包(war包或其它形式的包)布署到本地maven仓库和远程maven私服仓库

 

install命令完成了项目编译、单元测试、打包功能,同时把打好的可执行jar包(war包或其它形式的包)布署到本地maven仓库,但没有布署到远程maven私服仓库


deploy命令完成了项目编译、单元测试、打包功能,同时把打好的可执行jar包(war包或其它形式的包)布署到本地maven仓库和远程maven私服仓库  

相关文章:

  • 2021-10-21
  • 2022-01-24
  • 2021-05-27
  • 2021-06-26
  • 2021-12-19
  • 2021-12-15
猜你喜欢
  • 2021-04-13
  • 2021-10-08
  • 2021-07-14
  • 2021-11-09
  • 2021-08-14
相关资源
相似解决方案