-1

我有某些没有修订号的 jar 文件。但是由于 rev 是 ivy 依赖项的强制属性,所以我提供了 revision 属性。但是我-[revision]在 url 解析器中有类似 ( ) 的东西。
但它采用模块编号而不是忽略修订属性。我知道它不会忽略修订属性,因为它不为空。

以下是我得到的输出

 default-cache: no cached resolved revision for perltools#perltools;latest.integration
[ivy:retrieve]      tried httP://myrepo/ivyRepository/perltools/jars/[revision]/perltools-[revision].jar
[ivy:retrieve]  listing all in httP://myrepo/ivyRepository/perltools/jars/[revision]/perltools-[revision].jar
[ivy:retrieve]  using privateRepo to list all in httP://myrepo/ivyRepository/perltools/jars/
[ivy:retrieve] ApacheURLLister found URL=[httP://myrepo/ivyRepository/perltools/jars/perltools.jar].
[ivy:retrieve]      found 1 resources
[ivy:retrieve]  found revs: [perltools.jar]
[ivy:retrieve] HTTP response status: 404 url=httP://myrepo/ivyRepository/perltools/jars/perltools.jar/perltools-perltools.jar.jar
[ivy:retrieve] CLIENT ERROR: Not Found url=httP://myrepo/ivyRepository/perltools/jars/perltools.jar/perltools-perltools.jar.jar

有人可以解释为什么它以 module.ext 作为修订,而我指定的修订是 latest.integration 并且在 myrepo 中,我没有修订属性。

它只是有

[http://myrepo/ivyRepository/perltools/jars//perltools.jar]

有人可以帮助我,以便我可以避免修订属性吗?

4

2 回答 2

0

您可以只使用“latest.integration”作为修订版吗?

于 2011-01-29T05:20:41.807 回答
0

为了忽略修订并从 Jenkins 服务器下载 ZIP,我使用了一个解析器(in ivysettings.xml),比如

<url name="jenkins" m2compatible="true" checksums="">
    <artifact pattern="http://jenkins:8080/job/[organization]/ws/sources/[module]/*[ext]*/[artifact].[ext]" />
</url>

和一个依赖(在ivy.xml)喜欢

<dependency org="source-build" name="project" rev="+">
    <artifact name="project" type="zip" />
</dependency>

因此,我正在使用+修订版,因为latest.release只是没有正确解析,并且空字符串 ( rev="") 有效,但在本地缓存中留下了一个尾随破折号的工件,这是我不喜欢的。

请注意,由于Ivy 中的错误,我还必须在解析器定义中禁用校验和。

于 2012-11-09T10:13:56.277 回答