使用 Ivy 为 javadoc 指定 Web URL
===更新=== 我将尝试重新措辞以引起更多回应。 Ivy 中的 javadoc 工件必须是 jar 或 zip 文件吗?或者我可以将工件定义为类似于 http://download 的 URL。 oracle.com/javase/1.5.0/docs/api/?
我知道您可以将 Ivy 工件定义为从中下载文件的 url,但这不是我想要做的。
===原文===
我正在使用 Ivy 来处理由多个 Java 项目组成的大型项目的依赖关系管理。每个项目都由 Hudson 服务器编译并发布到 Ivy。每个项目都会构建运行时 jar、源 jar 和 javadoc jar。此外,Hudson 将 Javadoc 发布到 Web 服务器上的 URL。
我想要做的是在我的 ivy.xml 中为每个项目指定 Javadoc 在某个 URL 上发布。在我的依赖项目中,我想让 Ivy 解决该依赖关系并将其提供给 ant 中的 javadoc 命令作为子任务的参数。
最后,我想要以下内容:项目 A 在 http://someurl/A/javadoc 发布 javadoc 项目 B 依赖于 A,其 javadoc 发布于 http://someurl/B/javadoc 在项目 B 的 javadoc 中使用项目 A 中的类,我希望它链接到项目 A url。
有想法吗?
===Updated===
I'm going to try and re-word this to elicit more response. Does the javadoc artifact in Ivy have to be a jar or zip file? Or can I define the artifact to be a URL similar to http://download.oracle.com/javase/1.5.0/docs/api/?
I know you can define an Ivy artifact as a url to download the file from, but that is not what I want to do.
===Original===
I am using Ivy to handle dependency management for a large project that consists of multiple Java projects. Each project is compiled by a Hudson server and published to Ivy. Each project builds it runtime jar, a source jar, and a javadoc jar. Additionally, Hudson publishes the Javadoc to a URL on a web server.
What I want to do is specify in my ivy.xml for each project that the Javadoc is published at some URL. In my dependent projects I want to have Ivy resolve that dependency and provide it to a javadoc command in ant as arguments for the subtask.
In the end, I want the following: Project A has javadoc publish at http://someurl/A/javadoc
Project B is dependent on A and it's javadoc is published at http://someurl/B/javadoc
In Project B's javadoc where is use classes from Project A, I want it to link to the Project A url.
Ideas?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我想您应该像任何其他工件一样发布 Javadoc,并在 ivysettings.xml 中指定搜索模式。例子:
只要您将 Javadoc 作为工件发布,它就有自己的 ivy.xml,您可以在此处声明依赖项:
将 javadoc 工件描述为依赖项目的 ivy.xml 中的依赖项,然后在 build.xml 中指定 ant javadoc 任务依赖于根据需要执行和操作 javadoc jar 的目标(有关详细信息,请参阅 ant 文档)。
I guess you should publish Javadoc's as any other artifacts and specify search pattern in ivysettings.xml. Example:
As far as you publish Javadoc as artifact, it has its own ivy.xml and you can declare dependency here:
Describe javadoc artifact as dependency in dependent project's ivy.xml, then specify in your build.xml that ant javadoc task depends on target that performs and manipulate javadoc jar as you want (for details see ant documentation).