3
出於某種原因,當我使用scp
將文件從當前機器移動到使用ant
的服務器時,它始終忽略空目錄。Ant build and empty directories
<scp todir="[email protected]:/var/www/html" keyfile="${basedir}\..\keys\prod_default.pem" trust="true">
<fileset dir="${staging.dir}" />
</scp>
爲什麼?
完全更新詳細日誌:
D:\BUILD\SCRIPTS>ant -v -f getcom.xml update
Apache Ant(TM) version 1.8.2 compiled on December 20 2010
Buildfile: D:\BUILD\SCRIPTS\getcom.xml
Detected Java version: 1.7 in: C:\Program Files (x86)\Java\jdk1.7.0_02\jre
Detected OS: Windows Server 2008 R2
parsing buildfile D:\BUILD\SCRIPTS\getcom.xml with URI = file:/D:/BUILD/SCRIPTS/getcom.xml
Project base dir set to: D:\BUILD\SCRIPTS
parsing buildfile jar:file:/C:/ant/lib/ant.jar!/org/apache/tools/ant/antlib.xml
with URI = jar:file:/C:/ant/lib/ant.jar!/org/apache/tools/ant/antlib.xml from a zip file
[property] Loading D:\BUILD\SCRIPTS\build.properties
Build sequence for target(s) `update' is [update]
Complete build sequence is [update, upload, cleanup, staging, export, init, ]
update:
[exec] Current OS is Windows Server 2008 R2
[exec] Executing 'C:\\Program Files (x86)\\subversion\\bin\\\svn' with arguments:
[exec] 'update'
[exec] 'D:\BUILD\SCRIPTS\..\_STAGING\GETOM'
[exec] '--username'
[exec] 'uuuu'
[exec] '--password'
[exec] 'uuuu'
[exec]
[exec] The ' characters around the executable and arguments are
[exec] not part of the command.
[exec] Updating 'D:\BUILD\_STAGING\GETOM':
[exec] At revision 134.
[scp] Connecting to xx.0.0.100:22
[scp] done.
[scp] Connecting to xx.0.2.100:22
[scp] done.
BUILD SUCCESSFUL
Total time: 8 seconds
屬性:
svn.repoBaseURL="https://[email protected]"
svn.username="uuuu"
svn.password="uuuu"
svn.bin=C://Program Files (x86)//subversion//bin//
MSBuildPath=C://WINDOWS//Microsoft.NET//Framework//v4.0.30319//MSBuild.exe
lib.path.ant-contrib=C:/ant/lib/ant-contrib-1.0b3.jar
請注意,文件夾名稱已被更改。
你是否在詳細模式下運行它? – 2012-03-26 09:40:56
@AmitBhargava我已更新我的問題以顯示我在詳細模式下獲得的內容。 – Abs 2012-03-26 09:50:36
好吧,它似乎是字面上採取lib.path.ant-contrib而不是替換值。你能不能分享你的構建屬性文件? – 2012-03-26 11:10:57