2017-08-15 213 views
1

在有效POM我看到如何找到Maven的依賴,依賴關係:樹不起作用

<plugin> 
    <artifactId>maven-site-plugin</artifactId> 
    <version>3.3</version> 
    <executions> 
     <execution> 
     <id>default-site</id> 
     <phase>site</phase> 
     <goals> 
      <goal>site</goal> 
     </goals> 
     <configuration> 
      <outputDirectory>/home/tatiana/repos/selenium-tests/masbuilder-tests/target/site</outputDirectory> 
      <reportPlugins> 
      <reportPlugin> 
       <groupId>org.apache.maven.plugins</groupId> 
       <artifactId>maven-project-info-reports-plugin</artifactId> 
      </reportPlugin> 
      </reportPlugins> 
     </configuration> 
     </execution> 
     <execution> 
     <id>default-deploy</id> 
     <phase>site-deploy</phase> 
     <goals> 
      <goal>deploy</goal> 
     </goals> 
     <configuration> 
      <outputDirectory>/home/tatiana/repos/selenium-tests/masbuilder-tests/target/site</outputDirectory> 
      <reportPlugins> 
      <reportPlugin> 
       <groupId>org.apache.maven.plugins</groupId> 
       <artifactId>maven-project-info-reports-plugin</artifactId> 
      </reportPlugin> 
      </reportPlugins> 
     </configuration> 
     </execution> 
    </executions> 
    <configuration> 
     <outputDirectory>/home/tatiana/repos/selenium-tests/masbuilder-tests/target/site</outputDirectory> 
     <reportPlugins> 
     <reportPlugin> 
      <groupId>org.apache.maven.plugins</groupId> 
      <artifactId>maven-project-info-reports-plugin</artifactId> 
     </reportPlugin> 
     </reportPlugins> 
    </configuration> 
    </plugin> 

但我不使用Maven的網站插件,當我執行 MVN依賴性:樹

然後我沒有看到Maven的網站插件或輸出「網站」關鍵字或Maven的項目信息的報告,插件的任何提及。

同爲 MVN依賴性:樹-Dverbose

的問題是有效的POM錯誤,我想刪除: 元素reportplugins這裏不允許使用

也許這是有關與我使用的maven-surefire-plugin

+0

你確定你使用的某個庫沒有對maven-site-plugin的傳遞依賴嗎? – Makoto

+0

如何查看/查看?我試圖使用 mvn依賴:樹 - 混合 沒有成功(請參閱依賴關係,但不是這個) – Tatiana

+0

這聽起來你是從你正在使用的一些父母繼承這.. ..? – khmarbaise

回答

0

如果依賴已經存在與樹的更高的版本,那麼所有JRuby的完整的依賴性在樹深度較淺上市,因爲依賴關係樹的魔力梅乾較低水平的相關性。

您可以使用mvn dependency:tree -Dverbose=true來顯示省略的依賴關係。

+0

不,我仍然看不到maven-site-plugin那裏.. – Tatiana