【发布时间】:2013-02-22 07:48:19
【问题描述】:
首先,我对 ANT 很陌生,我对我面临的问题进行了很多研究,但没有取得任何成功。 我正在尝试获取 SVN 版本号。通过以下蚂蚁任务。我得到了修订号。但我想该修订号中有一个新行。当我将该数字附加到工件时,我看到了吗?在那。
<target name="revision-number" >
<loadfile srcfile="${basedir}/projectName/.svn/entries" property="revision">
<filterchain>
<headfilter lines="1" skip="3"/>
</filterchain>
</loadfile>
<echo file="REVISION" message="${revision}"/>
</target>
ZIP 逻辑在这里。
当我在 unix 终端中看到它显示的名称时 - projectName.12345?.tar.gz 并且在 winscp 中的名称是正确的 - projectName.12345.tar.gz
日志 [echo] 开始压缩 [tar] 构建 tar:/opt/maven/hudson/jobs/project/workspace/projectName.tar [gzip] 构建:/opt/maven/hudson/jobs/project/workspace/projectName.156308 [gzip] .tar.gz [echo] 停止 Zip
有两个[gzip]
使用 winscp 复制 .gz 文件时出现错误(错误代码 123) 所以我想剥离这条新线。
谢谢
【问题讨论】: