使用Ant 任务从 CVS 中Checkout源代码

build.xml
<project name="myApp" default="checkout">
    <property name="cvs.repository" value=":ssh:uer:[email protected]:22/home/cvsroot"/>
    <property name="cvs.package1" value="app1/code"/>
    <property name="cvs.package2" value="app2/code"/>
    <property name="cvs.package3" value="app3"/>
    <property name="source.dir" value="src"/>

    <target name="checkout">
        <cvs cvsroot="${cvs.repository}" package="${cvs.package2}" dest="${source.dir}"/>   
        <cvs cvsroot="${cvs.repository}" package="${cvs.package1}" dest="${source.dir}"/>
        <cvs cvsroot="${cvs.repository}" package="${cvs.package3}" dest="${source.dir}"/>
    </target>
</project>

执行这个文件,出现error=2错误
ant手册的cvstask中写到:
This task needs "cvs" on the path. If it isn't, you will get an error (such as error 2 on windows).
ant执行这个任务时需要cvs.exe, 安装TortoiseCVS即可;

你可能感兴趣的:(windows,xml,ant,cvs)