从Artifactory自动生成依赖项列表

时间:2022-08-09 00:09:36

Is there a way to auto generate list of dependencies from Artifactory, for every entry in artifactory. So I can then copy the needed entries for my projects instead of having to manually type each dependency by hand?

有没有办法从Artifactory自动生成依赖项列表,用于神器中的每个条目。那么我可以复制我的项目所需的条目,而不必手动手动键入每个依赖项?

3 个解决方案

#1


1  

Nexus, Artifactory and Archiva do not support this.

Nexus,Artifactory和Archiva不支持此功能。

You can instead run:

你可以改为运行:

mvn dependency:tree

And get the dependencies for your current project.

并获取当前项目的依赖项。

#2


0  

Artifactory is a binary repository, not a dependency manager. It barely saves the binaries and existing information about artifacts. Since we have no idea what build tool (and dependency manager) you are using, we don't know how to it generates the dependencies tree for you. We can give you information about a passed build (which was deployed previously to Artifactory). In this case we know de-facto what was resolved. But we can't know the dependencies in front (before you ran your tool).

Artifactory是二进制存储库,而不是依赖项管理器。它几乎不会保存有关工件的二进制文件和现有信息。由于我们不知道您正在使用什么构建工具(和依赖管理器),因此我们不知道如何为您生成依赖树。我们可以为您提供有关已传递构建的信息(之前已部署到Artifactory)。在这种情况下,我们知道事实上解决了什么。但我们无法知道前面的依赖项(在运行工具之前)。

#3


0  

seems artifactory doesn't do this, even though it knows every dependency in its repository

似乎artifactory不会这样做,即使它知道其存储库中的每个依赖项

ie:

即:

<dependency>
    <groupId>group1</groupId>
    <artifactId>artifact1</artifactId>
    <version>1.0</version>
</dependency>

since its a 'maven' repo it knows these three things for every jar added to it. Maven maven-dependency-plugin:tree does something different than listing all dependencies added to the repo

因为它是一个'maven'回购品,所以每增加一个罐子就知道这三件事。 Maven maven-dependency-plugin:tree与列出添加到repo的所有依赖项不同

#1


1  

Nexus, Artifactory and Archiva do not support this.

Nexus,Artifactory和Archiva不支持此功能。

You can instead run:

你可以改为运行:

mvn dependency:tree

And get the dependencies for your current project.

并获取当前项目的依赖项。

#2


0  

Artifactory is a binary repository, not a dependency manager. It barely saves the binaries and existing information about artifacts. Since we have no idea what build tool (and dependency manager) you are using, we don't know how to it generates the dependencies tree for you. We can give you information about a passed build (which was deployed previously to Artifactory). In this case we know de-facto what was resolved. But we can't know the dependencies in front (before you ran your tool).

Artifactory是二进制存储库,而不是依赖项管理器。它几乎不会保存有关工件的二进制文件和现有信息。由于我们不知道您正在使用什么构建工具(和依赖管理器),因此我们不知道如何为您生成依赖树。我们可以为您提供有关已传递构建的信息(之前已部署到Artifactory)。在这种情况下,我们知道事实上解决了什么。但我们无法知道前面的依赖项(在运行工具之前)。

#3


0  

seems artifactory doesn't do this, even though it knows every dependency in its repository

似乎artifactory不会这样做,即使它知道其存储库中的每个依赖项

ie:

即:

<dependency>
    <groupId>group1</groupId>
    <artifactId>artifact1</artifactId>
    <version>1.0</version>
</dependency>

since its a 'maven' repo it knows these three things for every jar added to it. Maven maven-dependency-plugin:tree does something different than listing all dependencies added to the repo

因为它是一个'maven'回购品,所以每增加一个罐子就知道这三件事。 Maven maven-dependency-plugin:tree与列出添加到repo的所有依赖项不同