问题描述
限时送ChatGPT账号..我在使用 ant build.xml 连接到 CVS 时遇到问题.我发现原因是 CVS 任务的包属性中的空格为:
I have problems connecting to CVS using ant build.xml. I figured out the reason was whitespaces in package attribute of CVS task as:
<cvs cvsRoot=":pserver:user@xx.xxx.xxx.xx:/CVSREPO_CCP_MIG" dest="${basedir}" package="My Test Project"/>
我从蚂蚁网站(http://ant.apache/manual/Tasks/cvs.html ),我们可以使用嵌套的
I learned from the ant website( http://ant.apache/manual/Tasks/cvs.html ) that we may Use a nested <module> element if you want to specify a module with spaces in its name. This specifies a package/module to work on, unlike the package attribute, modules specified using this attribute can contain spaces in their name.
我尝试使用以下方法:
<cvs cvsRoot=":pserver:user@xx.xxx.xxx.xx:/CVSREPO_CCP_MIG" dest="${basedir}">
<module name="My Test Project"/>
</cvs>
这再次抱怨:
build.xml:39: cvs doesn't support the nested "module" element.
如何使用带有 CVS 标签的模块元素?
How can I use the module element with the CVS tag?
Ant 版本是 1.7.x.
The Ant version is 1.7.x.
推荐答案
正如上面的评论所建议的,嵌套的module"元素可用于 Ant ver 1.8 +.
但是,如果您使用的是较早版本之一,则可以在 CVS 任务的包属性下通过添加"来指定包/模块名称在属性值的两端.
例如我们可以在此处将 package="My Test Project" 替换为 package="My Test Project"".
As suggested by the comments above, the nested "module" element is available for Ant ver 1.8 +.
However, if you are on one of the earlier versions, you may specify your package/module name under package attribute of CVS task by adding '"' on the either end of the attribute value.
e.g. We can replace package="My Test Project" with package=""My Test Project"" in here.
这篇关于在 ant build.xml 中的 cvs 任务中使用嵌套元素模块的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
更多推荐
[db:关键词]
发布评论