【发布时间】:2011-01-20 14:35:12
【问题描述】:
我的 ant 脚本在 Eclipse 中运行良好 这是其中的一部分:
<p2.composite.repository failOnExists="true">
<repository location="file:/${basedir}/compRepo" name="Repository description goes here" />
<add>
<repository location="http://url/Eclipse/repo/Galileo-3.5.1/" />
<repository location="http://another-url/Java/repo/4.0/" />
<repository location="${diag.location}" />
</add>
</p2.composite.repository>
但我希望 Hudson CI 服务器能够运行它,但是,无论我放入 ANT_HOME/lib 中的所有 jar 包,我都无法让这个任务在简单的命令行 ant 中运行...... 我遇到了这个错误:
C:\workspaces\workspace\project\junit.script\createCompRepo.xml:10: Problem: failed to create task or type p2.composite.repository
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any <presetdef>/<macrodef> declarations have taken place.
p2 ant 任务在哪里定义?有没有办法在 Eclipse 之外运行它们? 非常感谢您的帮助! 安东尼
【问题讨论】:
-
我已更新我的答案以反映您的发现。注意:Andrew Niefer(PDE/Build、p2 和 Equinox 框架上的 Eclipse 提交者)确实提出了您可能想阅读的有趣评论(我也将其包含在我的回答中)