ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Muthyala, Sunil" <>
Subject RE: Task help
Date Wed, 18 Oct 2006 18:22:31 GMT
Thanks to Jan and Steve Loughran.

I tried Jan's suggestion, I get an error

I downloaded the Ant-contrib-0.6.jar and dropped it in ant/lib directory and
included the <taskdef> in build.xml.

Here is the build.xml

<project name="CF" default="vss">
<taskdef resource="net/sf/antcontrib/"/>

<target name="cf">
<loadfile property="list" file="C:\vss_home\cffiles.txt"/>
    <ac:for param="file" list="list" delimiter=";">
            <echo> @{file} </echo>

<target name="vss" depends="cf">
<vssget localPath="C:\vss_home"
<echo message="VSS-GET successful"/>
This is the error I get

C:\apache-ant-1.6.5\bin>ant -f C:\apache-ant-1.6.5\build_AC.xml
Buildfile: C:\apache-ant-1.6.5\build_AC.xml

C:\apache-ant-1.6.5\build_AC.xml:6: The prefix "ac" for element "ac:for" is
not bound.

Total time: 0 seconds

What mistake I am doing?


-----Original Message-----
From: [] 
Sent: Tuesday, October 17, 2006 10:19 AM
Subject: AW: Task help

>1.	How to unzip a folder on a remote server (Windows NT), 
>I am unable
>to nest it inside of FTP.
>I am zipping a folder on local machine and FTP'ing it to the 
>server, but I need to unzip it in tmp folder and move the 
>unzipped folder to the right path on the server. Does REXEC 
>work for windows box?

Try <sshexec> - its more secure ...

>2.	I want to read the txt or doc which has full path and 
>file names of
>files to be pulled from VSS.
>I need to feed the contents of this txt file as input to the 
>vsspath, I tried using LOADFILE and saving it as property, but 
>it reads only first line and not the subsequent. Does ANT have 
>a for loop kind of command or any other to this kind of job.

<loadfile> should load the whole file into a property.
Ant-Contrib has a <for> which you can feed with that value.

    <loadfile property="list" file="..."/>
    <ac:for param="file" list="list" delimiter=";">
            <echo> @{file} </echo>


To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message