文章正文

Maven将文件打包到指定

【文档】2020-04-23

简介Maven将文件打包到指定

 解决方法:使用maven-dependency-plugin插件

<plugin>
   <groupId>org.apache.maven.plugins</groupId>  
   <artifactId>maven-dependency-plugin</artifactId>  
   <version>2.8</version>  
   <executions>  
       <execution>  
           <id>copy-war</id>  
           <phase>package</phase>  
           <goals>  
               <goal>copy</goal>  
           </goals>  
           <configuration>  
               <artifactItems>  
                   <artifactItem>  
                       <groupId>${project.groupId}</groupId>  
                       <artifactId>${project.artifactId}</artifactId>  
                       <version>${project.version}</version>  
                       <type>${project.packaging}</type>  
                   </artifactItem>  
               </artifactItems>  
               <outputDirectory>${dist.console.war.dir}</outputDirectory>  
               <includes>   
                   <include>*.war</include>   
               </includes>  
           </configuration>  
       </execution>  
   </executions>  
</plugin>

打赏支持

感谢您的支持,加油!

打开微信扫码打赏,你说多少就多少

找书费时,联系客服快速查找!

扫码支持

在线客服8:30-22:30,若离线请留言!

获取教程,请联系在线客服!

扫码支持

在线客服8:30-22:30,若离线请留言!

热门阅读

找PDF电子书,太费时间?

  • 微信扫描二维码,让客服快速查找。
  • 在线客服8:30-22:00,若离线请留言!