使用maven聚合安装多个maven工程到本地仓库报错的解决方法:child module pom.xml does not exist
                                                            生活随笔
收集整理的這篇文章主要介紹了
                                使用maven聚合安装多个maven工程到本地仓库报错的解决方法:child module pom.xml does not exist
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.                        
                                轉自:?https://stackoverflow.com/questions/26021141/maven-child-module-does-not-exist
1)在maven項目Parent中的 pom.xml 中 使用聚合安裝多個 maven工程到本地倉庫,pom配置如下:
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"><modelVersion>4.0.0</modelVersion><groupId>com.atguigu.maven</groupId><artifactId>Parent</artifactId><version>0.0.1-SNAPSHOT</version><packaging>pom</packaging><modules><module>../Hello</module><module>../HelloFriend</module><module>../OutFriends</module><module>../MakeFriends</module></modules>右鍵該pom.xml 執行 mvn install , 報錯信息如下:
[INFO] Scanning for projects... [ERROR] [ERROR] Some problems were encountered while processing the POMs: [ERROR] Child module E:\bench-cluster\spring_in_action_eclipse\Parent\..\Hello of E:\bench-cluster\spring_in_action_eclipse\Parent\pom.xml does not exist @ [ERROR] Child module E:\bench-cluster\spring_in_action_eclipse\Parent\..\HelloFriend of E:\bench-cluster\spring_in_action_eclipse\Parent\pom.xml does not exist @解決方法是:使用如下聚合配置
<!-- 通過modules 聲明聚合安裝的工程名稱 ,然后統一install,且工程間的放置順序可以隨意 --> <profiles><profile><modules><module>../Hello</module><module>../HelloFriend</module><module>../OutFriends</module><module>../MakeFriends</module></modules></profile></profiles>最后 pom.xml 右鍵 -> maven install 安裝成功。 bingo。總結
以上是生活随笔為你收集整理的使用maven聚合安装多个maven工程到本地仓库报错的解决方法:child module pom.xml does not exist的全部內容,希望文章能夠幫你解決所遇到的問題。
                            
                        - 上一篇: mybatis generator U
 - 下一篇: DDOS攻击技术(ddos防攻击技术)