0
我想將我的代碼從(tortoise)svn文件夾簽出到其他工作目錄。svn checkout不能與build.xml一起工作
在build.xml如下:
<?xml version="1.0"?>
<project name="svn-test" basedir="." default="checkoutThis">
<property file="build.properties" />
<path id="project.classpath">
<pathelement location="C:\Program Files\apache-ant\ant-1.8.2\lib\jsvn-0.9-dev.jar" />
<pathelement location="C:\Program Files\apache-ant\ant-1.8.2\lib\commons-lang-2.3.jar" />
<pathelement location="C:\Program Files\apache-ant\ant-1.8.2\lib\jakarta-regexp-1.3.jar" />
<pathelement location="C:\Program Files\apache-ant\ant-1.8.2\lib\svnant.jar"/>
<pathelement location="C:\Program Files\apache-ant\ant-1.8.2\lib\svnClientAdapter.jar"/>
<pathelement location="C:\Program Files\apache-ant\ant-1.8.2\lib\svnkit.jar"/>
<pathelement location="C:\Program Files\apache-ant\ant-1.8.2\lib\svnjavahl.jar"/>
</path>
<typedef resource="org/tigris/subversion/svnant/svnantlib.xml" classpath="C:\Program Files\apache-ant\ant-1.8.2\lib\svnant.jar;C:\Program Files\apache-ant\ant-1.8.2\lib\svnClientAdapter.jar;C:\Program Files\apache-ant\ant-1.8.2\lib\svnkit.jar;C:\Program Files\apache-ant\ant-1.8.2\lib\svnjavahl.jar" />
<target name="checkoutThis">
<svn username="sss" password="sss">
<checkout url="https://svn.strobilanthes.com/svn/nutanstplus/" revision="HEAD" destPath="Sample_SVN" />
</svn>
</target>
<target name="build" depends="checkoutThis">
<description>Main target</description>
</target>
</project>
運行build.xml文件時,它顯示:
E:\ant-for-example>ant
Buildfile: E:\ant-for-example\build.xml
checkoutThis:
[svn] <Checkout> started ...
不過,這並不在該文件夾中的文件複製。