且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

Maven在远程文件存储库中找不到工件

更新时间:2023-01-19 09:41:16

您可能想简单地尝试将罐子安装到本地存储库中,而只是跳过远程方面. Maven会先进入本地存储库,然后再进行远程操作.

You might want to simply try installing the jars into a local repository and just skip the remote aspect. Maven will look in the local repository before going remote.

安装第三方JAR的指南

创建一个pom进行复制,并将其绑定到process-resources阶段.您可以从已知位置(不要签入VCS;不当做法,浪费空间)拉出它们(例如:scp/robocopy/unzip)并安装它们.

Create a single pom to doing the copying, tie it to the process-resources phase. You can pull them (eg: scp/robocopy/unzip) from a known location (don't check into a VCS; bad practice, wasted space) and install them.

fyi,这与以太蚂蚁Tasks的工作相反,后者从amaven存储库中提取并复制到目标目录,这对于使用(nexus)存储库中的jar的蚂蚁构建非常有用,请参阅:

fyi, this is the opposite to what aether-ant Tasks does, which is pull from amaven repository and copy to a target directory, useful for ant builds to use jars from a (nexus) repository, see:

以太/蚂蚁任务

Apache Ant和Eclipse Aether