![](/img/trans.png)
[英]How do I figure out what maven artifacts to include in my POM after looking at the list of imports?
[英]How do I include a maven package that has invalid/outdated POM?
我想在我的項目中使用名為sourcemap
的 package。 它在 maven Central 中不可用,但在Atlassian 的公共 maven 存儲庫中可用。 因此,我像這樣設置我的pom.xml
:
<repositories>
<repository>
<id>atlassian</id>
<name>Atlassian</name>
<url>https://packages.atlassian.com/content/repositories/atlassian-public/</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>com.atlassian.sourcemap</groupId>
<artifactId>sourcemap</artifactId>
<version>1.7.7</version>
</dependency>
</dependencies>
現在,sourcemap 的 POM 文件從名為public-pom
的sourcemap
引用另一個 POM 文件:
<!-- POM for sourcemap (NOT my pom.xml!) -->
<parent>
<groupId>com.atlassian.pom</groupId>
<artifactId>public-pom</artifactId>
<version>3.0.84</version>
</parent>
問題:POM 文件引用了public-pom
的 3.0.84 版本,但 Atlassian 的 repo 不再提供 3.0.84。 目前,可用的最舊版本的public-pom
是 5.0.0,你可以在這里看到。 因此,當我嘗試構建項目時,maven 會抱怨:
Could not find artifact com.atlassian.pom:public-pom:pom:3.0.84 in atlassian (https://packages.atlassian.com/content/repositories/atlassian-public/)
如何修復 POM 並在我的項目中使用這個 package?
Mvnrepository 列出com.atlassian.pom:public-pom:pom:3.0.84
但在選擇鏈接時:
status: 404
message: "Could not find resource"
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.